Socket
Socket
Sign inDemoInstall

@sensecare/calibration-curve-chart

Package Overview
Dependencies
3
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @sensecare/calibration-curve-chart

calibrationCurve


Version published
Weekly downloads
1
Maintainers
1
Install size
54.3 MB
Created
Weekly downloads
 

Readme

Source

校准曲线图

  • 基于Echrets封装的校准曲线图

image.png

/**
 * 校准曲线
 * @param {string} id 当前选中容器
 * @param {string} xname x轴名称
 * @param {string} yname y轴名称
 * @param {*} thresholdLineData 带有阈值的线段信息 
 * @param {*} comLineData 折线信息 
 * @param {*} chartMap 当前图表实例组合
 * @param {*} config 默认配置项
 * @param {*} clear 清空画布
 */

  import { initCalibrationCurve } from '~'

    const chartMap = new Map()
    // x轴 y轴名称
    const xname = 'Nomogram-predicted(%)',yname = 'Obsevrved(%)';

    // 带有阈值的线段信息
    const thresholdLineData = [
      {
        color:'#6e8bad',
        data:[ [22,8],[22,38] ], // 两个点的信息
      },
      {
        color:'#6e8bad',
        data:[ [76,59],[76,91] ], // 两个点的信息
      },
      {
        color:'#6e8bad',
        data:[ [90,76],[90,100] ], // 两个点的信息
      },
      {
        color:'#6e8bad',
        data:[ [98,70],[98,95] ], // 两个点的信息
      },
    ]
    // 折线信息
    let comLineData= [[22,20],[76,82],[90,99],[98,92]]

    // 配置信息
    const config = {
      showLegend:false , // 是否显示图例,默认为true
    }
    // 初始化校准曲线
    initCalibrationCurve({ xname,yname,thresholdLineData,comLineData,id:'calibrationCurve',chartMap,config })

Keywords

FAQs

Last updated on 21 Oct 2022

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc