* Net EPS C$0.23 vs year-earlier loss C$0.03
* Comparable EPS C$0.10 vs analysts' forecast C$0.10
* Revenue down slightly at C$582 million
* Shares up 0.8 percent on TSX at open (Adds details, analyst's comments; updates share price)
TORONTO, July 29 (Reuters) - TransAlta Corp (TA.TO), Canada's biggest publicly owned electricity producer, reported a quarterly profit on Thursday versus a year-earlier loss, but said it does not anticipate a noticeable market recovery until next year.
The company, known for coal- and gas-fired power plants and renewable energy facilities in Canada and the United States, reported net income of C$51 million ($49.5 million), or 23 Canadian cents a share, in the second quarter. That compares with a loss of C$6 million, or 3 Canadian cents, in the year-before quarter.
Comparable earnings, which exclude most one-time items, were C$21 million, or 10 Canadian cents a share, versus a loss of C$6 million, or 3 Canadian cents.
Analysts on average had forecast comparable earnings of 10 Canadian cents a share, according to Thomson Reuters I/B/E/S.
"We continue to demonstrate sustainable operating and cost improvements across our fleet and especially at our Alberta thermal facilities," Steve Snyder, the Calgary-based company's chief executive said in a statement. "While markets improved briefly in the quarter, overall we do not anticipate a noticeable market recovery until 2011."
Chad Friess, an analyst at UBS, said in a note to clients that his firm is also cautious on TransAlta's prospects for the second half, given the poor outlook for natural gas prices, which play a large role in the power market.
"Under the specter of persistently weak gas prices we believe electricity demand in Alberta must improve materially to tighten the market," he said. "Underlining the cautious outlook, no new capital spending was announced as debt repayment remains a priority, though we see spare capacity in 2011."
Cash flow, a measure of a company's ability to fund new projects, rose to C$98 million from C$57 million in the year-earlier quarter.
For the full year, TransAlta said it expects to generate C$800 million to C$900 million in cash flow from operations. That is down from the forecast the company issued last quarter for C$850 million to $950 million in cash flow for the year.
The amount of TransAlta's power-generating capacity that was running in the quarter averaged 81.9 percent, down from 82.8 percent the year before.
Last month, a unit at the company's largest generating station, the Sundance coal-fueled plant in Alberta, suffered a mechanical failure that will force it run at at reduced capacity for as long as two years.
Revenue fell to C$582 million from C$585 million.
TransAlta shares were up 16 Canadian cents at C$20.67 on Toronto Stock Exchange on Thursday morning.
$1=$1.03 Canadian Reporting by John McCrank; editing by Peter Galloway