我正在使用HighStock股票图表库来生成基本的OHLC股票图表.我想在生成图表时(以及通过更改显示的时间框架重新生成图表后)执行某些操作.我正在尝试使用plotOptions.ohlc.events.show
事件(文档)来做到这一点.
我遇到的问题是甚至没有开火.如果我按照单击事件的示例,则单击该系列时警报会正确触发.
var chart = new Highcharts.StockChart({
chart: {
renderTo: 'divChart',
height: 450
},
rangeSelector: {
selected: 2
},
xAxis: {
maxZoom: 14 * 24 * 3600000
},
yAxis: [{
title: {
text: 'OHLC'
},
height: 200,
lineWidth: 2
}, {
title: {
text: 'Volume'
},
top: 250,
height: 100,
offset: 0,
lineWidth: 2
}],
title: {
text: 'Stock Chart'
},
series: [{
type: 'ohlc',
name: 'Prices',
id: 'prices',
data: …
Run Code Online (Sandbox Code Playgroud) I am using Highstock to show time based values. I need to get the date range shown in the chart for other purposes. Is there some easy way to get the begin-end values?
是否可以在点击点而不是鼠标移动时使用工具提示.
我已尝试在java脚本警报中显示值,如下所示
plotOptions: {
series: {
cursor: 'pointer',
point: {
events: {
click: function() {
alert ('Category: '+ this.category +', value: '+ this.y);
}
}
}
}
}
Run Code Online (Sandbox Code Playgroud)
要求是在点击时显示高图表工具提示.
请帮忙.谢谢!
我遇到了问题,无法呈现 TreeMap 图表。其他图表类型(如 Line)在我的应用程序中运行良好。我得到的错误是错误#17。我使用的是 Angular 5。你能分享任何使用 Angular5 和 Highcharts for TreeMap 的工作示例吗?
感谢您的快速帮助。
我在我的网站上使用highstock.使用SVG绘制股票图表导航器中的滚动条.我想在用户滚动到最左端时向图表添加更多数据(通过ajax).
我是SVG的新手,不知道如何检测用户是否已滚动到最后并根据该查询触发ajax查询.谁能帮我这个.
谢谢,Sivakumar.
我想知道如何自定义自定义按钮的工具提示.
所有自定义按钮的例子是像这样用_titleKey: 'printButtonTitle'
将此设置为其他任何内容都会导致undefined
工具提示.我花了一段时间来查看源代码,但是无法找到它.
此外,虽然使用像id这样的东西,并用jquery替换它,$('#foo-button title').html('yey');
但自定义按钮没有分配id.
我们能用高压做泡沫图吗?如果是的话我需要帮助,因为我这样做,但它不起作用:
$(function () {
$('#container').highcharts('StockChart',{
chart: {
type: 'bubble',
},
title: {
text: 'Highcharts Bubbles'
},
series: [{
data: [[Date.UTC(1970, 9, 27),97,36,79],
[Date.UTC(1970, 10, 10),94,74,60],
[Date.UTC(1970, 10, 18),68,76,58],
]
}]
});
});
Run Code Online (Sandbox Code Playgroud)
谢谢
我试图使用带有导航窗口的Highstock图表作为基于页面上的时间过滤某些内容的方法.
理想情况下,我希望用户将导航器缩小到感兴趣的时间,并能够将开始和结束日期/时间传递给过滤页面的按钮.
有谁知道如何从图表中提取这些日期/时间?
提前致谢
戴夫
有谁知道如何在highcharts中动态添加或删除"导出"按钮?
我已经能够使用类似于此的代码成功添加按钮:
exporting: {
buttons: {
customButton: {
text: 'Custom Button',
onclick: function () {
alert('You pressed the button!');
}
}
}
}
Run Code Online (Sandbox Code Playgroud)
但我希望以后能够通过javascript事件将该按钮添加到图表中(然后很快将其删除).
我的Highchart中的工具提示表现得很奇怪.它过着自己的生活.它没有显示我悬停点的工具提示,但随机显示任意点的工具提示.
这是一个JSFiddle示例:http://jsfiddle.net/AeV7h/9/
$(function () {
var data=[[28,0],[24,3],[16,10]];
var param= { WodTag: "cur_spd", Name: "Current speed", Color: "#C6C6C6", LineStyle: "Solid", SeriesType: "line", LineWidth: 2, TickInterval: null, MinValue: null, MaxValue: null, Decimals: 2 };
$('#container').highcharts({
chart: {
height: 700,
width: 400,
plotBorderWidth: 1,
plotBorderColor: '#E4E4E4',
},
xAxis: {
title: {
useHTML: true,
text: param.Name + "( m/s )",
},
gridLineWidth: 1,
min: param.MinValue,
max: param.MaxValue,
gridLineDashStyle: 'Dot',
tickInterval: param.TickInterval
},
yAxis: {
title: {
text: 'Depth(m)',
},
reversed: true, …
Run Code Online (Sandbox Code Playgroud) highcharts ×10
highstock ×10
javascript ×4
angular5 ×1
bubble-chart ×1
charts ×1
highlight ×1
hover ×1
jquery ×1
svg ×1
tooltip ×1