Houston broke open a seven-run lead with a six-run third inning. All the runs came with two outs.
The big inning provided plenty of run support for Kyle Weiland, who gave up two runs on four hits in three innings. The right-hander is competing for the Astros' fifth-starter spot.
Martinez delivered a two-run single and Chris Johnson added an RBI single in Houston's big third.
Marlins right-hander Anibal Sanchez was lifted for lefty Wade LeBlanc, who hadn't allowed a run in his first 10 1/3 innings of the spring. But the first batter he faced, Wallace, uncorked a three-run homer down the right-field line.
"That was an absolutely beautiful swing," Astros manager Brad Mills said. "He crushed that ball off a left-hander on the inside part of the plate. He got the bat head on it and kept it fair. That's nice to see."
Said Wallace: "I feel like the last four or five games, I've really kind of found my timing and started to hit my stride. I'm feeling good in the box and hitting the ball well. Hopefully I can keep it up and take it into the season."
Sanchez, projected as Miami's fifth starter, was making his second Grapefruit League start. He had been bothered by soreness in the back of his throwing shoulder.
The righty was charged with six runs on seven hits with four strikeouts and no walks. Key for the right-hander was he threw 38 of his 49 pitches for strikes. And his velocity topped at 94 mph, another encouraging sign showing that the sore right shoulder that kept him out the first few weeks of the spring is not an issue.
"I just need to stretch it out," Sanchez said. "I need to throw more pitches, like 70 pitches. But right now, I feel OK."
Gaby Sanchez drove in two runs for Miami with a single in the third inning.
Up next: Miami sends its ace, Josh Johnson, to the mound on Tuesday at 1:05 p.m. ET against the Rays at Roger Dean Stadium. The right-hander is 1-0 with a 1.29 ERA this spring, striking out seven in seven innings. Hanley Ramirez, John Buck and Sanchez are among the expected regulars to play. Wade Davis will pitch for Tampa Bay.