@khammad,
In order to load a local file on browser, you need to have a local server running in your system to avoid cross origin requests which most of the browsers doesn’t support. You can read data directly from a local text file (sample.txt), please take a look at this sample project.
__
Priyanka M S
Team CanvasJS