How can I set individual marker size on stock marker series in Anychart? - anychart

How can I set individual marker size on STOCK MARKER series? It works fine on basic MARKER series: https://docs.anychart.com/Basic_Charts/Marker_Chart#individual_points

The Stock chart implements a special mode that supports individual point settings. Usually, it is required for coloring but it also supports marker sizing too.
Here is the sample.
Pay attention to the chart data and line 19. The true argument is required to enable this mode.

Related

A way to set PriceScale width in Lightweight charts?

I have two charts (one for price, one for volume). I keep them in sync by usingthe various API observer functions. Works wonders.
Except the price scale width - I can get it using the priceScale('right').width() call, but I don't see any way to set it.
I'd like to be able to keep the width of both chart's price scales in sync (and keep them set to the max width of the two).
Thanks!
Currently it is not possible to set or adjust the price scale width. The price scale adjusts its width to ensure that the tick marks remain fully visible.
It is however possible to have the volume and price within a single chart if that would suit your needs. Here is an example:
https://jsfiddle.net/TradingView/cnbamtuh/
However if you wish to stick with two separate charts then I can suggest a hacky work-around for ensuring that the price scales line up correctly (for charts with the price scale on the right).
Firstly, you can set a custom price formatter to try ensure that the price strings are roughly the same width. This can be done by setting the localization property on the chart options (either during createChart() or with chart.applyOptions() (https://tradingview.github.io/lightweight-charts/docs/api/interfaces/ChartOptions).
chart.applyOptions({
localization: {
priceFormatter: (p) => `${p.toFixed(2).padEnd(10)}`,
},
});
If you set a custom font family which is monospaced then you might already have a working solution.
Docs for changing font family: https://tradingview.github.io/lightweight-charts/docs/api/interfaces/LayoutOptions#fontfamily
Example for changing the font family: https://jsfiddle.net/TradingView/po7wzr69/
However if you stick with the default fonts then you will most likely need to do the following step as well.
You can then measure the widths of each priceScale using series.priceScale().width() (https://tradingview.github.io/lightweight-charts/docs/api/interfaces/IPriceScaleApi) and manually adjust the chart sizes using an inline style on the container element for the chart
const margin = largestPriceScaleWidth - currentPriceScaleWidth;
const element = document.querySelector('#container-one');
element.style.width = `calc(100% - ${margin}px)`;

How can I hide absolute numbers from the tooltip on a Pie Chart in Google Data Studio?

I have a Google Data Studio pie chart showing the % of the Record Count metric, for various slices, but on hover, the tooltip shows the absolute number of Record Count. I don't want to share the absolute numbers with the customer receiving this report. How can I hide that?
Unfortunately it seems not possible as of now, here is the same question in the official support forum.
As stated by a user, the only possible workaround is to add a trasparent square over the chart, this would prevent the hover functionality to work.
Define your metric used in the pie chart as a percentage by setting the Comparison Calculation field to "percent of total". When hovering the mouse, something in the format 10%(10%) will be displayed on the card. Thus, the absolute value does not appear, even if the percentage is doubled.

AnyStock - can an annotation be represented in the chart scroller?

I would like to show the location of vertical annotations in the stock chart scroller so that when the user zooms/pans away from the annotation, they are still aware of its location on the chart.
Unfortunately, the current version of the library 8.7.0 doesn't support annotations and markers in the stock scroller. It can show a series thumbnail only.

SSRS bar chart issue

I am trying to add one box and one line on x-axis. Please look at below bar chart.
I tried using stripline but I cannot set height for stripline. It goes till 100.
Is there any way I can do this?
Unfortunately, SSRS doesn't provide the functionality you're looking for. A stripline is the closest you can get to that, but like you said, you can't control its height. The only way you could simulate this behavior would be to use a Background Image for your stripline, but that may be more work than it's worth. It would require a lot of manual adjustment to get the image to line up on the chart.
I would add a series to the chart using the Stock chart (under Range). In the Series Properties I would set the High value to the height desired for your line (~52 in your example). Ideally this would come from a dataset value.
Set the Low, Open and Close values to 0.
Try two Stripe Lines. First, create the strip line which represents the vertical value you're after. In my case, I made one that was 50% of the graph height off of the Y-Axis.
Chart Properties:
Height of StripeLine:
Once the stripe line is the correct height for the chart, create a 'mask' stripe line along the X-axis that will cover the portion of the Y-axis line you want hidden.
Chart Propterites:
Width of Stripe Mask:
Using these methods, and some really clever expression writing, you should be able to make the line exactly as high, and as wide as you desire.

Silverlight toolkit chart too many labels on axis

I'm using the newest chart control from silverlight toolkit to plot some data. For small cases it works ok, but for bigger samples the X axis labels overlap. It would be no problem if the chart would simply omit some of the values or I could specify to just show every 10th of them ...
I couldn't find any properties providing this behavior. Any ideas?
Assuming this is a Linear axis then you can specify the interval to use via the the Interval property on the axis.
If the axis in question is Category Axis then dropping some labels may not be valuable to the user. One option is to use the LayoutTransfomer to rotate the labels to an angle reducing the width needed for each one. See this Delay Blog on the subject.

Resources