Trying to use ProjectionY on TGraph

Dear experts,
I have a txt data about my project. I can read and draw this data with TGraph. I want to fit certain range of my data. I have a chart and I want to fit only the min and max values ​​of this chart. I’m using the ProjectionY command, but I’m getting an error from the terminal.

TGraph *graph2 = new TGraph(“5Mv_CH3.txt”);
graph2-> ProjectionY()->Draw();

For now I am trying to get Y axis. But it seems like ProjectionY doesn’t even work.

Regards.
..png

TGraph