How to calculate open price of a stock

What factors are used to calculate the opening price of a stock?