FVANCOP / ChartNew.js

MIT License
420 stars 141 forks source link

Interactive charting with Chart.js #407

Open soodrah opened 8 years ago

soodrah commented 8 years ago

Hi Fvancop, Is it possible to do interactive line charts with chart.js. Meaning if I move my mouse then based on my mouse movement on the canvas the line is drawn. See the attached gif green dashed line and red dashed lines are the lines that can be moved by pulling it with mouse or drawn from scratch by just starting the mouse from the red triangle or green triangle only and not from any other position, can chart.js do that. If not how long will it take to add this feature.

If you look at the Y axis it has two triangles one in red color and one in green color. They permanently stay on the y axis, how can i draw that on the Y axis. screen shot 2016-01-04 at 8 57 01 pm

FVANCOP commented 8 years ago

I'm pretty sure that it is possible, but it needs some development;

When I have terminated with my current development (fix bugs discovered when running on iPhone), I will try to do it, but I do not have lot of free time for the moment to work on it....

Some information on how to implement it (perhaps that you or someone else will be able to create an add-ins for it) : -> detect that a click is performed on the chart and the position of the click (see Samples/mouse_actions.html) -> Add a line definition in your data using the shapesInCharts.js (I think it will be easier to use shapesInCharts.js but I'm not sure); -> update the chart.

soodrah commented 8 years ago

hi Francois Will appreciate if you can implement it. I am not good in java script at all, it will take me a long time to figure it out. I will still take a look based on what you hinted. Can you give me a time estimate of how soon you can get it done.

On Tue, Jan 5, 2016 at 2:38 AM, Francois Vancoppenolle < notifications@github.com> wrote:

I'm pretty sure that it is possible, but it needs some development;

When I have terminated with my current development (fix bugs discovered when running on iPhone), I will try to do it, but I do not have lot of free time for the moment to work on it....

Some information on how to implement it (perhaps that you or someone else will be able to create an add-ins for it) : -> detect that a click is performed on the chart and the position of the click (see Samples/mouse_actions.html) -> Add a line definition in your data using the shapesInCharts.js (I think it will be easier to use shapesInCharts.js but I'm not sure); -> update the chart.

— Reply to this email directly or view it on GitHub https://github.com/FVANCOP/ChartNew.js/issues/407#issuecomment-168924410 .

Rahul Sood Software Engineer/Java Developer/Web Developer/C++Programmer/JasperReports and IText Developer/Expert in J2EE, JSF, HTML, Javascript, EJB2.1 etc.

Work Experience Includes companies like Credit Suisse MICROS (Leader in Hospitality Industry) Lockheed Martin (Defence Leader) DUKE Medical Center Carefirst Blue Cross Blue Shield C 9195610975