Trading and gambling are closely related the same as investment and gambling are very closely related. I think trading can be counted as gambling just because your hoping for higher prices when it may never come.
If you are trading hoping to see an higher price then you are effectively gambling but all the traders that make money trading do not do that, they look at the charts an apply principles that have been tested over and over again and by following them they are able to get some profits.