Masahiro Tanaka threw seven shutout innings in a win over...

Masahiro Tanaka threw seven shutout innings in a win over the Houston Astros in Game 5 of the 2017 American League Championship Series at Yankee Stadium. Credit: Newsday / Thomas A. Ferrara

TAMPA, Fla. — Masahiro Tanaka said he wasn’t tempted.

“I really prioritized what I felt inside,” Tanaka said Wednesday morning after working out at the Yankees’ minor-league complex. “I’m sure there were possibilities, but the important thing for me was to follow what my heart was saying, and that’s what I did.”

Tanaka had an out clause, which could have made him a free agent, in the seven-year, $155-million contract he signed before the 2014 season. But he wanted to stay put. Period.

“I’ve been with the organization for four years, going into my fifth year,” Tanaka, 29, said through his translator. “My thought was I want to go out and battle with these guys again, try to get where we want to get [the World Series], so that was kind of my thought process.”

Given the glacial pace of free-agent signings — and the recent fiery rhetoric between the MLBPA and MLB — Tanaka made the right decision. “It was good to know where I was going earlier,” said Tanaka, who arrived Tuesday.

Of course, when Tanaka announced in November that he would not opt out, “you would never know it was going to turn into something like this” for free agents, he said Wednesday.

After going 39-16 with a 3.12 ERA in his first three seasons in pinstripes, he was 13-12, 4.74. He allowed a combined 62 homers his first three seasons, then gave up more than half that many last year (35).

Masahiro Tanaka threw seven shutout innings in a win over...

Masahiro Tanaka threw seven shutout innings in a win over the Houston Astros in Game 5 of the 2017 American League Championship Series at Yankee Stadium. Credit: Jim McIsaac

“Not going into too much details, but I think I do understand why that happened,” Tanaka said. “You go in and make the necessary adjustments so it doesn’t happen again.”

Tanaka’s 2017, however, wasn’t the bust the numbers might suggest. He was 5-7 with a 6.34 ERA after his 14th start of the season June 17. He recovered to go 8-4 with a 3.54 ERA in his last 16 starts, and he said he hopes to build on his second half. Tanaka allowed 21 homers in those first 14 starts compared with 14 over the last 16 outings. He was terrific in the postseason — 2-1, 0.90 ERA — which included eight strikeouts in seven innings in a 5-0 win over the Astros in Game 5 of the ALCS that put the Yankees within one victory of the World Series.

“At the start of the season it was really shaky,” Tanaka said. “I felt like I was making adjustments during the season and finally it seemed like everything came together toward the end. My thought process right now is to just try to go into the season from where I left off last season.”

At the start of the offseason it seemed a fait accompli, according to many, that Tanaka would be joined in the rotation by Japanese star Shohei Ohtani, but the pitcher/outfielder eliminated the Yankees early in the process, eventually choosing the Angels.

Tanaka acknowledged being “a little bit” disappointed.

“A player of that caliber, you want to be on the same team,” he said, “but we’re in the same league and will play each other. I think it will be good for the Japanese baseball fans.”

Tanaka has played for only one manager, Joe Girardi, in the big leagues but said he had no concerns about new manager Aaron Boone, to whom he hasn’t spoken.

“I’m not worried about anything, it’s more a positive curiosity of how he’s going to run the team and go about his business,” Tanaka said. “Just really looking forward to playing under him.”

More Yankees headlines

SUBSCRIBE

Unlimited Digital AccessOnly 25¢for 5 months

ACT NOWSALE ENDS SOON | CANCEL ANYTIME ONLINE