BOSTON — Most scientists conduct their experiments in the seclusion of their labs, far away from eyes that might judge their work before they’ve reached conclusions. Back in 2008, when they were pitching together with the Kansas City Royals, Brian Bannister and Zack Greinke conducted their experiments in front of more than 37,000 people.

Bannister and Greinke had come across early data on pitch velocity and movement generated by a camera system mounted at major-league stadiums, a system now widely known as PITCHF/x. Perhaps unwittingly, Major League Baseball had made the raw data accessible to anyone who knew how to download it. By 2007, amateur baseball analysts had uncovered and begun to convert the data into a form that was accessible to people without advanced programming skills.

The beneficiaries of their work included Bannister and Greinke. What set Bannister and Greinke apart from other analysts was not just that their livelihood depended on the data but that they could affect the data being collected.

“It really turned my world upside down,” Bannister said.

Bannister now works as the director of pitching analysis for the Red Sox. Greinke will pitch on Sunday for the Arizona Diamondbacks, the team that signed him to a $206.5-million contract in December. Both continue to utilize and benefit from the data they first discovered almost 10 years ago.

Though most pitchers on their team and other teams ignored the data, Bannister and Greinke couldn’t get enough. They wanted to understand how their pitches worked and what they might do to improve them. They began to conduct impromptu experiments, manipulating the data as best they could. The obstacle they faced was that the only time they generated data was when they were pitching in major-league games against major-league hitters in major-league stadiums.

“I remember Greinke and I would try to see if we could improve our spin or improve the movement of our pitch — and we’d literally go check in between innings,” Bannister said.

If they could have generated data somewhere else — in spring training, in the bullpen, on a Little League field in suburban Kansas City — they’d have thrown their experimental pitches there. That was not an option. They had to conduct their experiments in major-league games.

“We were very careful about it, and it was really only in blowout games,” Bannister said. “But the system only existed mounted permanently in major-league stadiums. If it had been in the bullpen, that’s where we would have done it. If it had existed in the offseason somewhere, we would have used it then. But you literally had to be pitching in a major-league game in order to get access to it.”

Bannister was not blessed with the natural ability that has made Greinke one of the game’s best pitchers for close to a decade. What allowed Bannister to reach and gain a toehold in the major leagues, however brief, was information.

He studied the greats of the game, be it heroes of his youth such as Kevin Brown or Nolan Ryan or contemporary greats Roy Halladay, Felix Hernandez, Justin Verlander and, yes, Greinke. The newly available PITCHF/x data allowed him to identify the characteristics that set the greats apart from the also-rans like himself.

“If you want to learn how to build an iPhone, you smash it to pieces and look what’s inside,” he said. “I’d take all of the best pitchers in the game and look at how their pitches move and then look at how mine didn’t move — and I was like, ‘Wow.’ For me, it just established this gap between the physical talent and ability of the best pitchers. Then I’d get into, ‘How do I maximize the stuff I have?’ It’s telling me I don’t spin the ball very fast. I don’t throw very hard. I don’t create good angles. What do I do well?’ "

One truism Bannister and Greinke learned not to be quite so true involved the changeup. The best changeups in the game, they found, aren’t the changeups with the greatest differential in velocity from the fastballs that go with them. The best changeups in the game have the most movement.

Early in his career, Greinke threw a changeup that came in around 80 mph. By 2009, his Cy Young Award season, the pitch was averaging 84.1 mph. It has averaged around 88 in each of the last two seasons.

“The name of the pitch is almost deceiving,” Bannister said. “What I spent years trying to do was take more speed off it. We always watched James Shields, Felix Hernandez, and their changeups didn’t look like anybody else’s. Everybody was telling us, ‘Hold this circle change grip and just throw it slower.’ These guys, their ball is going straight down. They’re actually manipulating it. Those were the ‘Aha’ movements. My last year, in 2009, my ground-ball percentage went up before I got hurt like 10 percent that year, and it was purely because I’d figured out how to make my changeup move. Greinke is still using that today.”