A week after he moved into the circa-1800 farmhouse he had always dreamed of owning, David Evans spotted something glinting in his backyard. Within two hours, he had unearthed 19 spark plugs. The discovery was no surprise. He knew his home had been a junkyard for the preceding 40 years -- that's one reason he bought it. Without the spark plugs, windshield wipers and rotting transoms that dot his garden -- as well as the not-so-appealing fact of having a trailer park and an abandoned gas station as neighbors -- Evans and his partner, Jorge Ruiz, antiques dealers in the small Lowcountry town of Walterboro, S.C., say they could never have afforded the area's oldest farmhouse. When the challenging location and troubled economy drove down the seller's asking price from $296,000 to $170,000, the home was finally within reach, and a few months ago, the couple bought it. A similar house would cost 35 percent more in a different location, according to Charles H. Bridges of United Country Joe Williams & Associates, the broker who sold them the house, which is about 45 minutes west of Charleston. Houses like theirs are 'the petunia in the onion patch,' says Gary Gestson, a broker with Long & Foster Real Estate in Gaithersburg, Md. They are charming and often historic, but bargains because their neighborhoods have long since vanished or become blighted. Real estate agents warn against buying a good house in an undesirable area, saying location trumps all. But because the price is often so appealing, it is a way for buyers to get some of what they want without spending a fortune. As a curator of exhibitions for the New-York Historical Society, Kathleen Hulser is passionate about the past. She craved an antique home, but with her salary, she knew she would have to compromise. That compromise is a freight train that blasts by just a few feet from her four-bedroom 1839 summer house on the Housatonic River in Cornwall Bridge, Conn. It appears at 7:30 a.m. almost every day. 'The house shakes,' Hulser said. 'It rattles the pots and pans.' She bought the house last August for $255,000, reduced from $375,000, said her broker, Priscilla Miller of Bain Real Estate, after it had been on the market for 10 months. 'Without the train next door,' Miller said, the house would have cost double. 'It made it much more affordable by putting up with that,' she said. To make the outlay even smaller, Hulser shared the cost with her brother, Michael. The train wasn't the only factor depressing the price of the house. Next door is a former Superfund site where an old factory dumped chemicals. Hulser does not mind the toxic past because the site has been cleaned and certified by the government as fully decontaminated. To Hulser, the formerly toxic site and the currently noisy train are no worse than the air and noise pollution in Harlem, where she lives during the week. Indeed, she finds the train appealing. 'The conductor always waves,' she said. 'It almost counts as a charming defect.' The train is not roaring through hourly; it runs on average once a day, at most twice. But not everyone is charmed. Hulser said that when her 12-year-old daughter, Kira Baird, had a sleepover party, she 'tried to spin it as a quaint feature of the site.' When the train thundered by that Saturday morning, though, Hulser awoke to a chorus of pre-teens shrieking in terror. Safety can be an issue. Hulser must remind her daughter's guests not to leave bicycles on the tracks, which, just 20 feet from her house, are so little used that they blend into the scenery. For Hulser, the historic building trumps all. 'I grew up on houses like this,' she said. 'It's the equivalent of comfort food in architecture.' Eridania Diaz, 48, feels the same way. When she was a little girl growing up in the Dominican Republic, she sobbed when her mother replaced the family radio with a new model. 'I see new things as beautiful,' she said, 'but they don't have that something.' So in 2004, when her husband, Simon, a salesman, told her about the crumbling 1901 Federal-style house with a colonnaded wrap-around porch in the Highbridge section of the Bronx that he had seen when he was out on business, Diaz had to have it. But the object of her affection stands among a half-dozen burned-out boarded-up shells. And Highbridge, which borders Yankee Stadium, numbers among New York City's most unsafe areas, according to statistics from the New York Police Department. 'When I came here I didn't notice the neighborhood,' Diaz said. She saw only the fireplaces, each flanked by hand-carved Art Nouveau female figures, and the soaring mahogany spiral staircase that climbs toward a vaulted ceiling. 'We were able to get the house because of the neighborhood,' said her daughter, Erika, who lives there with her family. 'This house in another neighborhood, we wouldn't be able to afford.' They paid $350,000 for the 10-room house in 2004. It cost about that much to haul away over 10 tons of trash, remodel and install surveillance cameras and alarms. Though she said she loves the house, Diaz, who is a landlord, recently put it on the market because she said that economic troubles had left many of her tenants unable to pay their rent, which has reduced her income. She said she plans to move into a similar antique house a few streets away if she sells the property. For Kevin Miske, 38, who lives alone, indulging his love of old buildings by buying one in a neighborhood he could afford has worked out. He paid $675,000 for a 9,000-square-foot home plus a 1,000-square-foot coach house -- significantly less than the $1.1-million asking price. But just after he closed in 2004 on the turn-of-the-century two-story town house on the seedy side of the Garfield Park neighborhood of Chicago, thieves broke in. Miske bought a second dog. 'I needed something intimidating,' said Miske of the 160-pound South African mastiff that now patrols his yard. 'He's a very gentle dog, but visually he's intimidating.' He feels safe, but drug deals and prostitution are part of the neighborhood landscape. 'If I had a family I would perhaps think differently,' he said. 'If I was worried about the security of my wife and children, I wouldn't do this.' Sometimes safety is in the eye of the beholder. When Gwynn Griffith first invited her girlfriends to her new home on the south side of the river in San Antonio for their weekly card game, they carpooled. They were afraid, she said, of a drive-by shooting. Her home, a shoe manufacturing plant built in the 1800s, cost $80,000 in 1994, and Griffith, a decorator with an opulent flair, has spent $400,000 creating a lavish space that conjures a ruined European castle. Not all improvements are aesthetic: She's spent nearly $7,000 on stockade fencing alone. 'I've kind of made a fortress out of it because of the neighborhood,' she says. When she's inside the three-story, 16,000-square-foot factory, towering over a sea of tiny, shabby buildings, Griffith says she feels transported. She says she has never felt unsafe in her palazzo-like enclave, although she hears gunshots some evenings. 'I have a more desirable building in just a less desirable area,' she said. Skeptics are won over by what Griffith has done, said Chris Hill, a friend and real estate developer. 'You do kind of wonder when you stop to buy beer on the way at all the bulletproof glass around the gas station down the street,' he said, 'but once you get there, you forget all about that.' When she first saw the property, there were old boats and rusted cars in the yard, pigeons roosting indoors and a resident colony of bats. 'They'd swoop in and fly around and eat all the mosquitoes,' she said. 'I thought it was kind of charming.' Like many people who own houses where the location is unlikely to improve, Griffith will probably never see a return on her investment. Because that is often a risk, Marjorie Ellena, a co-owner of HistoricProperties.com, a real estate listing service for antique homes, warns buyers away from such properties. But emotional reactions can be powerful. Anne Troutman, 53, found the desire for a taste of her New England birthplace in Santa Monica, Calif., so strong that five years ago she bought a church that reminded her of the architecture of her childhood. Then she turned it into a residence despite the fact that a homeless couple was, according to Troutman, 'bivouacked in the side yard.' Though at just over $1 million the house wasn't cheap, many comparable area homes are currently listed at more than double that price. That's because while the property sits two blocks from the sea, it's sandwiched between a day care center and a community center that also runs children's programs. (The sound of children playing, she said, is 'stereophonic.') Substance abusers come to the center for nightly support groups and congregate around her yard. Some mornings she wakes to find someone passed out on her doorstep. Because of the location and the run-down condition of the church, Troutman paid a third less than the asking price. Troutman, an artist and former architecture professor, and her husband, Aleks Istanbullu, 59, an architect, made an oral agreement with the homeless couple living in the yard: They stayed on as guardians of the vacant house until construction was complete, after which, they left -- sort of. 'They used to come back for weekends at the beach,' Troutman said. Some did not approve. Troutman's father, Richard Troutman, was unsettled by the homeless people and addicts camping out around the building. 'It's not exactly reassuring when you have a daughter who's maybe alone in the house,' he said. But the lofty ceilings, and the couple's deft renovations, he said, have since won him over. Troutman said she has come to see the neighborhood not as a blight but rather as something that connects her to reality. 'In L.A. especially, you can pick your perfect house and perfect neighborhood and find that you are completely divorced from real life,' she said. In contrast, her home 'is knitted into the community and all of its complexities.' It takes a certain personality to give up 'location, location, location' for 'house, house, house.' Evans, whose professional world is antiques, grew up in a 'cookie-cutter house' in Middletown, N.J., by the Jersey Shore. To him the sameness of modern houses is an anathema -- so much so that he's willing to put up with the beer bottles and candy wrappers that crop up like crab grass on the lawn, and the constant whiz of cars along the road that passes very close to his house. Would he prefer if his home were in a nicer locale? 'I would also love to be 6-foot-3' and muscled,' he said, 'but I'm not, and not going to be. And eventually we'll dig up all the spark plugs.' In the meantime, he said, 'It's kind of a funny cocktail party conversation.' 