"Puerto Rican Painting: Between Past and Present," the survey exhibition currently on view at the Museum of Modern Art of Latin America, 201 18th St. NW, is a scholarly and thorough and strangely moving show. It is not its beauty one remembers, but something far more touching. The painters represented, 34 in all, were trained in many lands (Mexico, Madrid, Paris and Manhattan); they work in many styles and follow many masters (Courbet and Picasso, Dali and Hans Hofmann. Yet an old and fevered longing ties their works together. A deep communal yearning for a distinctly Puerto Rican national identity unifies their show.

Step into the gallery and you can almost smell the plantains and the mangoes, the hot sun and the foliage, the politics and poverty of that poor, conflicted land.

Compared with that of other Latin nations, say Colombia or Mexico, its art history is meager. Until well into our century, Puerto Ricans who wished to see or study painting were forced to go abroad. Yet time and time again something tugged them home. Their returns were not triumphant. The modernists among them found that something in their homeland -- the poverty or heat or the ever-present weight of the colonial experience -- leached the daring from their art.

The greatly gifted Francisco Oller (1833-1917), with whom the show begins, was in the 1860s a close friend of Pissarro's, and also of Ce'zanne's, and a member in good standing of the avant-garde in Paris. As soon as he returned, his modernity diminished. His still lifes, although lovely, make one think more of Couture, his first teacher, than of Ce'zanne, and his commissioned public portraits have a Latinate pomposity that recalls the French salons. His homeland, so one gathers here, did little for his style. But it provided him a subject. Oller began painting not Normandy but Ponce. "Bode'gon," his early 1890s still life on display, depicts not pears or apples, but peppers and bananas.

The artist, Oller told his students, "must be of his country, of his people, if he wants to be authentic." Almost all the painters here have heeded his command.

A mix of foreign styles (often slightly retrograde) and Puerto Rican subjects recurs throughout this show. Of the 62 paintings on display, "El Pan Nuestro" ("Our Bread"), done in 1905 by the realist Ramo'n Frade (1875-1954), is perhaps the best known. It's a kind of national icon. A Puerto Rican peasant, a jibaro, straw-hatted and underfed, stands proudly as a monument on a verdant hillside. He holds not a loaf of bread or a sheaf of wheat, but a branch of green plantains.

That sort of Puerto Rican patriotism is frequently experienced here. Often it is blended with the surreality of dreams. In "The Wait" of 1933, a work by Juan Rosado (1891-1962), one of the few painters represented who never left his homeland, the waiting woman on the balcony looks out at a cityscape as desolate as those painted by de Chirico. By the 1950s, many Puerto Rican painters were combining that odd dreaminess with bitter social comment. "Juvenile Delinquency" (1960) by Felix Rodriguez Baez, with its knife fight and its jukebox, owes something to the island's bonding to Manhattan, and something to the '50s paintings of Ben Shahn.

It might have been the failures of "Operation Bootstrap"; it might have been the lessons of the Cuban Revolution, but whatever the source, some accusative anger, some new fury at old poverty, soon begins appearing in Puerto Rican art. Where houses poor but picturesque were once a favorite subject, these painters, in the '60s, begin showing slums as slums. The barefoot children in "Vita Cola" (1969), by Brooklyn-born Rafael Tufinåo, aren't heroes, merely victims. Frade's noble peasant reappears in Carlos Irizarry's "Transculturation" of 1975, but here he is accompanied by a tortured and eviscerated martyr-ghost.

Ghosts of other sorts stalk the exhibition. Francisco Rodo'n's striking 1974 portrait of the writer Rosario Ferre' shows her as a nun in a habit made of newsprint. In "Take-Over" (1985), Arnaldo Roche's strange self-portrait, a kind of dark-skinned imp-commander grows out of the artist's hair.

The Squibb Corp. has invested more than $100,000 in the Puerto Rican exhibition. Squibb commissioned Mari Carmen Ramirez, director of the University of Puerto Rico Museum, who put the show together and also wrote its useful catalogue. The company has also repainted the Washington museum. The show will travel to Squibb's corporate gallery in Princeton and then to Rio Piedras in Puerto Rico after closing here Sept. 2.