If you look at a graph plotting the cumulative American box-office earnings of most Hollywood movies over time, you’ll see something that looks like a Southwestern plateau — a hugely steep incline that then quickly flattens out. If you look at the same graph for “My Big Fat Greek Wedding,” the quirky romantic comedy from 2002, you’ll instead see a shape that looks like the front half of a boa constrictor that swallowed an elephant.

That’s because “My Big Fat Greek Wedding” did something seemingly impossible. Despite an unheralded cast, a budget of just $5 million and a small theatrical release, the film spent almost a year in theaters and earned more than $360 million (inflation-adjusted) at the domestic box office to become the second-highest-earning romantic comedy in history (behind “Pretty Woman”). Writer and star Nia Vardalos will try to recapture the magic when “My Big Fat Greek Wedding 2” comes out Friday. Opa!

In the process of smashing box-office expectations, the original film became what I’m calling the leggiest movie of the past 20 years, during which time more than 4,000 major films were released. It earned its honor because, well, the movie had legs. According to box-office research firm The Numbers, “My Big Fat Greek Wedding” has the highest ratio of total domestic box office to largest single-weekend gross of any film in that time period — and it’s not even particularly close. Four months after it opened in theaters, “My Big Fat Greek Wedding” had its largest weekend box-office haul — just more than $11 million. By the time it finally left theaters eight months after that, the film had a legginess ratio of nearly 22:1. The next closest films since then? “Birdman or (The Unexpected Virtue of Ignorance)” at about 17:1, “Bend It Like Beckham” at nearly 17:1, and “Napoleon Dynamite” at nearly 16:1. The average major film has a legginess ratio of about 3:1 and lasts about 12 weekends in theaters. “My Big Fat Greek Wedding” lasted for 50 weekends.

RANK MOVIE TOTAL BOX OFFICE EARNINGS BEST WEEKEND EARNINGS LEGGINESS RATIO 1 My Big Fat Greek Wedding $241.4m $11.1m 21.8 2 Titanic 658.7 35.5 18.6 3 Life Is Beautiful 57.6 3.2 17.8 4 Birdman 42.3 2.5 17.1 5 Bend It Like Beckham 32.5 2.0 16.7 6 Napoleon Dynamite 44.5 2.8 15.8 7 The English Patient 78.7 5.6 14.2 8 The Cider House Rules 57.5 4.1 14.2 9 The Queen 56.4 4.0 14.1 10 American Beauty 130.1 9.5 13.7 The leggiest major films of the past 20 years Domestic box office, not adjusted for inflation Source: The Numbers

“My Big Fat Greek Wedding” doesn’t seem like the kind of movie that would break records. After all, its description — frumpy girl with ridiculous ethnic family gets together with pushover WASP — seems like it would make for a bad sitcom. (And indeed, it eventually did become a bad sitcom.) Movie studios were wary from the beginning. Despite the backing of Playtone’s Tom Hanks and Rita Wilson, Vardalos was pressured by studio execs to bring on a more marketable star and change her family to a more recognizable ethnicity, like Italian. When the team pushed on instead with the smaller IFC Films as a distributor, producers were originally planning to release straight to HBO before deciding to open in theaters.

The movie launched in 108 U.S. theaters on April 19, 2002, with a tiny marketing budget — just more than $1 million for six weeks, according to Paul Brooks, CEO of Gold Circle Entertainment, which produced the film with Playtone. “We felt by that time, we would either see positive trending or we would be dead,” he told me. It made a respectable $5,531 per theater on opening weekend (typical take for a major movie was about $3,000 per theater). But then something strange happened. Most movies drop somewhere between 30 percent and 50 percent in per-screen revenue after week one — and keep dropping after that until they’re bringing in less than $1,000 per theater and they get replaced by another film. “My Big Fat Greek Wedding,” on the other hand, held steady, even as the number of theaters gradually increased. By the weekend of Aug. 30, 2002, it had spread to more than 1,600 theaters and pulled in an average $6,857 per location.

Vardalos was perplexed by the film’s ability to keep drawing crowds. “[I was] really, really, really surprised, and I still am,” she told the audience at the Hudson Union Society in 2013.

Gold Circle and Playtone supplemented the film’s marketing budget a bit as it pushed past its sixth week in theaters, Brooks said, and shifted some of the marketing so that it was pitched as a family comedy in addition to a romantic comedy. Bruce Nash, CEO of The Numbers, suspects that word started spreading from house to house that the movie was an easy, family-friendly way to spend a couple of hours. “‘My Big Fat Greek Wedding’ went viral when there wasn’t such a thing as going viral,” he said. It doesn’t hurt that the only other major PG movies that screened that year were sagas such as “Star Wars: Episode II – Attack of the Clones” or animated fare such as “Scooby-Doo.” And more people went to the movies in 2002 than any other year in history.

Indeed, legginess ratio is a useful stat for identifying original movies that thrive on good word of mouth. The only sequels among the top 100 leggiest movies ever are “The Empire Strikes Back” and “The Return of The Jedi” (and they’re only on there because they were rereleased — with more sarlacc tentacles! — for a few weeks in 1997). Not only does the ratio get rid of the influence of inflation, it also rewards films without huge marketing budgets that theater owners keep renewing week after week since they put butts in the seats.

Although action and adventure movies dominate the domestic box-office ranks since 1977, they’re nearly absent from the leggiest movie list. Only one from the past 20 years qualifies: “Crouching Tiger, Hidden Dragon,” a foreign-language film. (It, coincidentally, also got a sequel this year.) The leggy list — at least from the past two decades — is populated almost exclusively by dramas and comedies, which don’t usually make a lot of money and thus are not usually backed by a strong marketing push from day one. Since 1995, on average, major films in those genres make less than $15 million, while action and adventure movies take in more than $50 million each (in today’s dollars). Other weird little comedies are also in the top 10 of the leggy list, including “Napoleon Dynamite” and “Bend It Like Beckham.” And many of the other movies on the list are Oscar-nominated dramas and other films about abstract concepts that you won’t see until multiple people tell you they’re good.

One thing nearly all the 100 leggiest have in common: They’re all good. Only one — “The Phantom of the Opera” — has a Rotten Tomatoes rating that would be considered “rotten.” Many of the others are considered some of the finer films ever made. “My Big Fat Greek Wedding” (Rotten Tomatoes score: 76) is not one of those movies. But it did manage to become one of the most profitable films in history by lasting in theaters long after others had flamed out. This elephant-eating snake had legs.