Martinez suffered the injury after rounding first base on a fifth-inning single, then left for a pinch runner.
"It kind of grabbed me a little bit," he said after leaving the Tigers' 9-2 win over the Mets. "That's why I stopped."
Martinez said he was "just trying to push to make it to second, and you just feel it a little bit. So just [to] make sure, I'd better stop than keep going."
Following the game, Tigers manager Brad Ausmus said he was not overly concerned about Martinez's injury.
"I was concerned when it first happened because I thought it was his knee," Ausmus said. "But when I went out there, he said it was his hamstring. So that was a big sense of relief right there.
"But it seems to be a mild strain in the meat of the hamstring, which is good. So I'm sure he'll miss a couple of days. But I don't expect this to be lingering. It shouldn't affect his stolen-base numbers."
A year after struggling through an injury-riddled season, the 37-year-old Martinez had been feeling so healthy that he actually leads the Tigers in plate appearances this spring, with 31. And manager Brad Ausmus had been talking about playing him at first base later this week, to prepare him for some spot starts at first during the season.
The Tigers open the season in Miami, so they had hoped to play Martinez at first and move Miguel Cabrera to third base for at least one game in that series.
Martinez was noncommittal about how long the injury would keep him out, saying: "See how does it feel tomorrow and work from there."
But Martinez sounded unconcerned that the injury could cause any significant setbacks three weeks from Opening Day.
Asked if he was frustrated anyway, he laughed and replied: "No. I've been going through a lot more stuff tougher than this one."