bugfixing clinical trials
This commit is contained in:
parent
f022b458c4
commit
422cffa4d0
@ -4,10 +4,10 @@ import InfoModal from '$lib/components/InfoModal.svelte';
|
||||
import { Chart } from 'svelte-echarts'
|
||||
import { abbreviateNumber, formatString } from "$lib/utils";
|
||||
import { init, use } from 'echarts/core'
|
||||
import { LineChart } from 'echarts/charts'
|
||||
import { BarChart } from 'echarts/charts'
|
||||
import { GridComponent, TooltipComponent } from 'echarts/components'
|
||||
import { CanvasRenderer } from 'echarts/renderers'
|
||||
use([LineChart, GridComponent, TooltipComponent, CanvasRenderer])
|
||||
use([BarChart, GridComponent, TooltipComponent, CanvasRenderer])
|
||||
|
||||
export let data;
|
||||
|
||||
@ -147,6 +147,7 @@ function getPlotOptions() {
|
||||
],
|
||||
series: [
|
||||
{
|
||||
name: '# of Trials',
|
||||
data: valueList,
|
||||
type: 'bar',
|
||||
itemStyle: {
|
||||
|
||||
@ -159,7 +159,7 @@ async function plotData() {
|
||||
const { dates, seriesData } = filterDataByTimePeriod(rawData, timePeriod);
|
||||
|
||||
// Convert seriesData to the format required by the series property
|
||||
let series = Object.keys(seriesData).map(key => {
|
||||
let series = Object?.keys(seriesData).map(key => {
|
||||
return {
|
||||
name: key,
|
||||
data: seriesData[key],
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user