Where is the output in the LSTM? I'm trying to understand where the output of the LSTM is. Please refer to the following picture:

http://colah.github.io/posts/2015-08-Understanding-LSTMs/

It seems that at each tilmestep, we output h_t and C_t which correspond to the hidden state and the memory cell. 

Now suppose I'm trying to model the stock price movements which is binary [0,1], 0 for down, 1 for up which is my y_i.

I feed in x_t which is a feature vector at each tilmestep and I expect to get a 1 dimensional output y_t after the last tilmestep.

Are h_t what I'm looking for? This would imply that h_t matches the output dimension, but for some reason I though it is independent of the output dimension.
Usually you have to add a Dense layer after the LSTM unit. That will try to understand how to use the output of LSTM.

For example in Keras:

model = Sequential()
model.add(LSTM(4, input_shape=(1, 5)))
model.add(Dense(1, activation='sigmoid'))
model.compile(loss='binary_crossentropy', optimizer='adam')