m-chart icon indicating copy to clipboard operation
m-chart copied to clipboard

Highlight one line in the chart?

Open ReHWolution opened this issue 6 years ago • 10 comments

Hi methnen, I was wondering if there will be the option to highlight a single field in a chart, so that you could show what's the main focus of a chart. Thanks!

ReHWolution avatar Jun 10 '18 13:06 ReHWolution

I'm pretty sure that's quite doable and relatively easily at that. I'm not sure on an ETA though given that my main priority right now is to fully decouple Highcharts from the main plugin so I can get it listed on wordpress.org again. I'm in the midst of that work right now and it's quite a change so that release is likely to be very light on new features though I'll possibly be able to fit something like this in as well. We'll see.

methnen avatar Jun 10 '18 18:06 methnen

Just an update. Looked into this and it's not entirely straightforward like I'd hoped, but definitely doable. Need to think through what the UI for it would look like though.

Making this post to link to this forum reply where a Highcharts dev provided examples of how this might be done in Highcharts:

https://forum.highcharts.com/post142269.html?sid=886a7cee1d0ce329489156598e3b4e3b

methnen avatar Aug 13 '18 15:08 methnen

Oh, I see. But that would go against making the chart custom for the users that read it. They could change it too easily and lose the point of the chart. I'm very ignorant when it comes to programming, but maybe, some kind of check mark to select when doing a chart in order to change that row or column specific color?

ReHWolution avatar Aug 13 '18 15:08 ReHWolution

His method is interactive. I think just to demonstrate how it could be done.

I'm imagining something where the interaction happens on the Admin Panel end but is not changeable/interactive when someone views the chart.

Basically by choosing a point/series in the chart you'd be setting a parameter that gets used to highlight that data point for the visitors but they wouldn't be able to do the same on their end they'd just see a highlighted series/data point.

methnen avatar Aug 13 '18 16:08 methnen

Yes, yes, exactly. If you need a guinea pig, feel free to ask me. After all, we're also friends on Facebook :) (Ciro Sdino here) ;)

ReHWolution avatar Aug 13 '18 16:08 ReHWolution

@methnen dusting off this request to see if something changed in 6 years! Do you believe it is possible now to do such a thing as highlight a single line?

ReHWolution avatar Sep 12 '24 08:09 ReHWolution

@ReHWolution I have thought about this a bit more and I think maybe a custom one off version of how to do this would be best probably.

A few questions:

Are you still using the Highcharts version primarily?

Do you have or have you used the Advanced Custom Fields plugin at all?

methnen avatar Sep 12 '24 15:09 methnen

@ReHWolution I have thought about this a bit more and I think maybe a custom one off version of how to do this would be best probably.

A few questions:

Are you still using the Highcharts version primarily?

Do you have or have you used the Advanced Custom Fields plugin at all?

Hi! In order: No, at a certain point I started using the chart.js version, I only have the highchart plugin installed for compatibility with the old charts I did years ago. No, never used ACF!

ReHWolution avatar Sep 12 '24 16:09 ReHWolution

Got it, ok.

So I'm mentioning ACF because it provides a very fast way to prototype a new interface for anything basically.

I will test a method to do this on my dev setup and see if I can prototype something quickly.

If I succeed I'll let you know.

methnen avatar Sep 12 '24 16:09 methnen

Thanks a lot, it means so much!

ReHWolution avatar Sep 12 '24 16:09 ReHWolution

@ReHWolution I am still poking at this a bit.

Can you list which chart types you'd like to be able to do this on. I'm assuming line charts. But any others?

methnen avatar Sep 24 '24 04:09 methnen

Yes, line charts and maybe spline charts?

ReHWolution avatar Sep 24 '24 17:09 ReHWolution