Heartbeat

My heart has been feeling weird as of lately like a fluttery feeling in my chest, I heard it could be anxiety or magnesium deficiency and I was taking a medications hat could cause that but I’ve never really had and deficiency symptoms. But has anyone with anxiety ever dealt with this before