“We show that it is possible to determine socioeconomic statistics and political preferences in the US population by combining publicly available data with machine-learning methods,” said the report, published Tuesday in the Proceedings of the National Academy of Sciences.

The researchers created an algorithm to identify the brand, model and year of every car sold in the US since 1990.

The types of cars also provided information about the race, income and education levels of a neighborhood, the study said.

Volkswagens and Aston Martins were associated with white neighborhoods while Chryslers, Buicks and Oldsmobiles tended to appear in African-American neighborhoods, the study found.

The researchers cross-checked their predictions against actual Census Bureau data and voting results.

They said their method of surveying neighborhoods could eventually save the government time and money by replacing or supplementing the Census Bureau’s door-to-door approach with compilations of demographic information.

Tech blogger and Google critic Scott Cleland says “Once you start sharing and deducing people’s private stuff in a group setting for group purposes, it doesn’t take a genius to see that this could end badly.