How to set Y axis of a histogram

How one can set the Y axis scale of a histogram?

https://root.cern/doc/master/classTH1.html
scroll down a bit to Drawing Histograms.

With reference to it when i set Double_t maximum = 1 and Double_t minimum = -10 for y axis of an histogram then no effect occurred after it.

histogram->SetMaximum(...);
histogram->SetMinimum(...);