Whittaker Corp., a defense electronics, chemicals, metals and health-care conglomerate based in Los Angeles, yesterday posted a fourth-quarter deficit of $3 million (23 cents a share), but most of that was attributed to a loss on the sale of another company's stock.

In the fourth quarter of last year, Whittaker earned $5.9 million (41 cents). Revenue was $290.1 million in the most recent period compared with $337.1 million a year earlier.

Whittaker took a fourth-period loss of $2.3 million (17 cents) on the sale of its holdings in Smith International Inc., a oil-services firm based in Newport Beach that earlier this year lost a protracted and costly bid to take over Gearhart Industries Inc. of Fort Worth, Tex.

That brought Whittaker's loss for the year on its 1.6 million shares of Smith to $29 million, including previous write-downs of the stock.

For the year ended Oct. 31, Whittaker earned $19.9 million ($1.40) on sales of $1.13 billion compared with a year earlier when it earned $43.9 million ($3.01) on sales of $1.44 billion.

The first-quarter loss of Whittaker's lucrative contract to operate Saudi Arabia's health-care network was a significant setback for the company's revenue and earnings, said Joseph Alibrandi, Whittaker's president and chief executive.

*General Signal Corp. announced yesterday in New York that its board of directors approved a $44 million charge against fourth-quarter net earnings that will result in a loss for the period.

The fourth-quarter charge amounts to $1.53 a share and will result in a loss for the fourth quarter in contrast to earnings that otherwise roughly would have equalled those for the same period a year ago, the company said.

Through the first nine months, General Signal earned $2.50 a share. David T. Kimball, chairman of the technology and telecommunications company, which is based in Stamford, Conn., said the "recession in the semiconductor industry . . . will continue to influence results through much of 1986. Accordingly, earnings for the first part of 1986 will also be down from the prior year."