Calculate area under a highcharts curve - highcharts

I am looking for ways to calculate the area under a highcharts curve (integral). I have been looking but so far I haven't found nothing. Is there any tool available for me to do this?

Related

plotly.js "pseudo" histogram for time-series data?

I am trying to figure out how to create this overlaid plot of time-series data, where one of the series should "look" like a histogram.
The problem is I could not figure out how to combine/overlay a histogram with time series data and line/scatter plot and get the histogram xbins to work with the date time data, etc.
So I was also trying to use a bar chart, and create a "pseudo histogram" by removing the gaps between bars, adding outlines, and so forth but that seems fruitless as I don't see a way to control all the borders/lines to that level of control.
The result I am looking for is roughly like so;
Which to me looks like the best match for a plot type should be a histogram, but again I could not figure out how to make that work overlaid with the same x axis as the line/scatter time-series data.
Can anyone offer ideas or point me to an example that might help me understand how to do this ?
I guess I also need to figure out how to align the y-axis scales of the two series also, but that I expect is a different topic...
I am specifically using plotly.js / Javascript

Custom line styles for a given range

I'm trying to highlight a portion of a scatter/line plot, but using separate plots for each highlight and get them overlaid on top of the original plot is not working for me because the original plot is doing cubic curve smoothing and I need more points in the highlight than required for the curve to fit the one in the back.
I haven't found any delegate/data source way of specifying a line style for a given range in the documentation. Is there a way of achieving this?
If not possible, is my approach of multiple plots the way to go or is there something else you'd recommend?
There is no way to specify different line styles for separate data ranges. Your solution of multiple plots is the right one, although as you discovered, it won't work with smoothed lines.
You could do the smoothing yourself by turning off the curved line interpolation and adding additional plot points between the known data points. Then you would know where to separate the data for the individual plots.

iOS drawRect, finding points on a curve

I will draw a curve similar to the red curve in the illustration below (can be a bezier or whatever is most convenient for my purposes I think). I would like to find points on the curve (blue dots in the illo). The points would most likely be divisions of equal parts of the length of the curve.
Can I find these points? I am not seeing a solution in the docs as of yet.
This answer covers segmentation of a Bezier curve using the de Casteljau algorithm. You already have your parameterized values along the curve for segmentation.
(If you follow the link referenced in the answer make sure you have java enabled in your browser, so you can view the example visualisations).

How to detect PizzaMarker

did somebody tried to find a pizzamarker like this one with "only" OpenCV so far?
I was trying to detect this one but couldn't get good results so far. I do not know where this marker is in picture (no ROI is possible), the marker will be somewhere in the room (different ligthning effects) and not faceing orthoonal towards us. What I want - the corners and later the orientation of this marker extracted with the corners but first of all only the 5Corners. (up, down, left, right, center)
I was trying so far: threshold, noiseclearing, find contours but nothing realy helped for a good result. Chessboards or square markers are normaly found because of their (parallel) lines- i guess this can't help me here...
What is an easy way to find those markers?
How would you start?
Use other colorformat like HSV?
A step-by-step idea or tutorial would be realy helpfull. Cause i couldn't find tuts at the net. Maybe this marker isn't called pizzamarker -> does somebody knows the real name?
thx for help
First - thank you for all of your help.
It seems that several methods are usefull. Some more or less time expansive.
For me it was the easiest with a template matching but not with the same marker.
I used only a small part of it...
this can be found 5 times(4 times negative and one positive) in this new marker:
now I use only the 4 most negatives Points and the most positive and got my 5 points that I finaly wanted. To make this more sure, I check if they are close to each other and will do a cornerSubPix().
If you need something which can operate in real-time I'd go down the edge detection route and look for intersecting lines like these guys did. Seems fast and robust to lighting changes.
Read up on the Hough Line Transform in openCV to get started.
Addendum:
Black to White is the strongest edge you can have. If you create a gradient image and use the strongest edges found in the scene (via histogram or other) you will be able to limit the detection to only the black/white edges. Look for intersections. This should give you a small number of center points to apply Hough ellipse detection (or alternate) to. You could rotate in a template as a further check if you wish.
BTW.. OpenCV has Edge Detection, Hough transform and FitEllipse if you do go down this route.
actually this 'pizza' pattern is one of the building blocks of the haar featured used in the
Viola–Jones object detection framework.
So what I would do is compute the summed area table, or integral image using cv::integral(img) and then run exhaustive search for this pattern, on various scales (size dependant).
In each window you are using only 9 points (top-left, top-center, ..., bottom left).
You can train and use cvHaarDetectObjects to detect the marker using VJ.
Probably not the fastest method but it should work.
You can find more info on object detection methods using OpenCV here: http://opencv.willowgarage.com/documentation/object_detection.html

Best-fit hexagonal tilings of irregular areas

I'm looking for recommendations for an application or library to calculate good fits of regular hexagonal grids to an irregular area or group of areas.
Minimally, I'd like to be able to supply an image and maximum number of hexagons and retrieve the image that rotates/shifts/scales a hexagonal grid to fill each hexagon with one color with minimal error. An advanced feature might be to perform deformations of the underlying image (within specified limits) to achieve a better fit. I have some ideas of how I'd do this myself, but it seems likely to be a solved problem.
Thanks for any suggestions.
EDIT: The use-case I'm thinking of would be to generate reasonably faithful hex maps of real geography for use in board (or virtual board) games.
My general idea is to do the following:
you should to approximate your irregular Curve shape to a minimal linear segments
then, you may calculate the angle a between each couple of sements 90 < a <180.
There are few methods to approximate curves into lines: explained here

Resources