reactjs - 在 React 中使用 Dygraph 显示两个系列
问题描述
我想在 dygraph 中显示 2 个系列,但我不知道该怎么做,谢谢你的帮助。
这是我的代码:
let datas = [];
datas = state.logDatas.data;
new Dygraph (
'Two_series',
datas,
{
labels: ["key", "value"],
title: "",
width: 1000,
height: 400,
}
)
解决方案
我发现,两个系列的示例选项卡“数据”:
[
[1, null, 3],
[2, 2, null],
[3, null, 7],
[4, 6, null],
[5, null, 5],
[6, 4, null]
]
推荐阅读
- r - R for 循环:使用拆分创建数据帧?
- ruby - if vs Ruby中的短路评估
- node.js - In Node.js / Express how do I gain access to an object in app.js from a module 2 layers deep?
- html - 如何使用引导网格创建下一个列
- powerbi - Power BI - 每个类别的平均值
- python - Python 正则表达式用中间的数字替换查找正斜杠
- mysql - MySQL 服务器未在 Windows 中启动
- r - 使用“st_transform()”将坐标转换为另一个投影 - 创建地图时
- python - Fixing a while-loop to only run once
- python - How to terminate/killall a program in python