Contrasts were drawn between Occupy Vancouver's tent city and the city's own homeless shelters Thursday as a lawyer for a woman who lives on the streets argued in B.C. Supreme Court against removing the encampment.

Lawyer Michael McCubbin argued the makeshift village set up by protesters is safer and has become "closely intertwined" with homelessness, so much so that forcing it to be dismantled would deprive his client.

"Many of the circumstances and the problems that the city has with Occupy Vancouver -- as well as the movement's socio-economic grievances -- wouldn't exist if housing was not such an issue and not so insufficient in the city of Vancouver," McCubbin told Associate Chief Justice Anne MacKenzie.

He said about 26 homeless people are currently living in tents on the lawn of the city art gallery, which was set up Oct. 15 as part of the global Occupy movement that highlights the few world's rich against many more of the population who are poor.

Of the group, 22 are men and four are women.

McCubbin said his 28-year-old client, who he's representing for free, would face risks of sexual and physical violence if the tent city didn't exist.

Court heard the results of an informal survey of campers at Occupy Vancouver asking whether the site provided a safe place that wouldn't otherwise be available. It found eight of 12 women agreed, along with another 26 of 33 men.

Asked whether city shelters were a safe refuge, nine of 12 women disagreed, along with 23 of 33 men.

"It's the best information we have," he said.

McCubbin quoted the survey, which asked campers to describe their living conditions.

"I feel safer at Occupy Vancouver than any shelter," said a woman estimated in the survey to be 19 years old. "I'm not worried about getting followed by creepy men or getting hit on."

Another respondent, a man estimated to be 50 years old, described shelters as "smelly," while another 50-year-old said he was ganged up on at shelters because he is aboriginal. He said people at Occupy Vancouver are teaching him to read and write.

A 19-year-old respondent noted she could fall asleep at Occupy Vancouver knowing none of her personal belongings would get stolen.

"It's so much more private and you can have your own blankets," she said. "Everyone is super smart, everyone is super nice."

McCubbin suggested the sentiments show the site offers a feeling of community, safety and social enrichment that homeless people wouldn't encounter otherwise. Violence, drugs, alcohol, theft, insecurity and a lack of privacy are also concerns in city shelters.

"These are actually bigger problems in the shelters than at the Occupy Vancouver site," he said.

McCubbin referred to Metro Vancouver's annual homeless count, conducted last March, which notes a shortfall of about 465 shelter beds in Vancouver compared with the number needed.

There's never been an exact figure for how many people are residing overnight at the site. The city fire chief initially said upwards of 60 people slept in tents, and as the weather got wet and cooler, reduced it to as few as 15 to 25.

Numerous tents and structures have been removed and spaced further apart since the city was granted an interim order allowing firefighters to enforce safety regulations.

In October, British Columbia's housing minister announced the province would be funding fewer emergency shelters in downtown Vancouver, citing an increase in permanent residence in year-round shelters.

McCubbin is the first of several lawyers, each representing different members of the tent city, who are trying to stop the city's request for an injunction ordering the campers to clear out.

City lawyers say the camp amounts to trespassing and should be dismantled because protesters are breaking city bylaws.

A similar issue has been tested in British Columbia courts before. The province's highest court ruled in late 2009 that homeless people can camp temporarily in public parks if municipalities can't provide them with sufficient alternative shelter.

The ruling struck down a Victoria bylaw that had banned camping in city parks by the homeless.

The Vancouver-related arguments were made as Occupy protesters held an afternoon march around the downtown offices of Brookfield Asset Management, the firm that owns the New York City park where Occupy Wall Street demonstrators clashed with police early Tuesday.

Five Occupy Toronto protesters plan to appear before an Ontario Superior Court on Friday to argue an eviction order made by that city is unconstitutional.