How can I display time and date in separate lines along xaxis in QML chartview line series - charts

I am able to display epoch value to Date and Time strings along x-axis in QML Chartview Lineseries. But, I want to split the time and date into separate lines as shown in the attachment.
Can someone please help me on this.
Below is the sample code
Window {
width: 640
height: 480
visible: true
title: qsTr("Hello World")
property var lineSeries
property var x1Val : [1649736833, 1649740465, 1649744065, 1649747665, 1649751265, 1649754865, 1649758465, 1649762065, 1649765665, 1649769265]
property var y1Val : [0,1,2,3,4,5,6,7,8,9]
Component.onCompleted: {
for(var i = 0; i < 2; i++) {
lineSeries = chartView.createSeries(ChartView.SeriesTypeLine, "strend" + i)
lineSeries.axisX = axisx2
lineSeries.axisY = axisy2
for(var iLoop = 0; iLoop < x1Val.length; iLoop++) {
lineSeries.append(x1Val[iLoop] * 1000 + (i * 10000000), y1Val[iLoop])
}
}
}
ChartView {
x: 0
y: 0
width: 640
height: 480
id: chartView
DateTimeAxis {
id: axisx2
min: new Date(1649736833000)
max: new Date(1649779265000)
//format: "yyyy/MM/dd hh:mm"
format: "hh:mm yyyy/MM/dd"
}
ValueAxis {
id: axisy2
min: 0
max: 10
}
}
}
Expected Output

use the format like below. This aligns the time to center of the date.
format: "     hh:mmyyyy/MM/dd"
//where &#160 - spacing character in HTML
Thank you all for your help

Related

why two combined image collections show 0 elements in the console of the google earth engine?

I used the .combine command to convert two image collections into a two-band image collection (in the last line) to use in a function in the next step. This command is executed but writes 0 elements in the console. Where does this problem come from?
code link :
https://code.earthengine.google.com/5ebed42b397e764e3229e3f224c8b643
code :
var Rad1 = ee.ImageCollection('ECMWF/ERA5_LAND/HOURLY')
.filter(ee.Filter.date('2018-10-24','2019-05-20'))
.select('surface_solar_radiation_downwards');
var Rad2 = ee.ImageCollection('ECMWF/ERA5_LAND/HOURLY')
.filter(ee.Filter.date('2019-05-20','2019-06-30'))
.select('surface_solar_radiation_downwards');
var Rad1_Mj = Rad1.map(function(img){
var bands = img.multiply(0.000001);
var clip = bands.clip(geometry);
return clip
.copyProperties(img,['system:time_start','system:time_end']); });
//print(Rad1_Mj);
var Rad2_Mj = Rad2.map(function(img){
var bands = img.multiply(0.000001);
var clip = bands.clip(geometry);
return clip
.copyProperties(img,['system:time_start','system:time_end']); });
//print(Rad2_Mj);
// time frame change function for median collection
var daily_product_median = function(collection, start, count, interval, units){
var sequence = ee.List.sequence(0, ee.Number(count).subtract(1));
var origin_date = ee.Date(start);
return ee.ImageCollection(sequence.map(function(i){
var start_date = origin_date.advance(ee.Number(interval).multiply(i),units);
var end_date =
origin_date.advance(ee.Number(interval).multiply(ee.Number(i).add(1)),units);
return collection.filterDate(start_date, end_date).median()
.set('system:time_start',start_date.millis())
.set('system:time_end',end_date.millis());
}))};
// daily radiation product
var daily_Rad_1 = daily_product_median(Rad1_Mj,'2018-10-24', 208 , 24 , 'hour');
// print(daily_Rad_1);
//Map.addLayer(daily_Rad_1, {min: 17.38, max: 26.07, palette :
['white','yellow','orange']},
'Daily solar shortwave radiation 1' );
var daily_Rad_2 = daily_product_median(Rad2_Mj,'2019-05-20', 41 , 24 , 'hour');
// print(daily_Rad_2);
// Map.addLayer(daily_Rad_2, {min: 23.77, max: 26.64, palette :
['white','yellow','orange']},
'Daily solar shortwave radiation 2');
var daily_Rad_total = daily_Rad_1.merge(daily_Rad_2);
//print(daily_Rad_total);
var START = '2018-10-24';
var END = '2019-06-30';
var DATES = [ '2018-12-19', '2018-12-29', '2019-01-23', '2019-02-12', '2019-03-04',
'2019-03-19', '2019-04-08', '2019-04-13', '2019-05-13', '2019-05-18', '2019-05-23',
'2019-05-28', '2019-06-02', '2019-06-07', '2019-06-12', '2019-06-17', '2019-06-22',
'2019-06-27'];
var addTime = function(x) {
return x.set('Date', ee.Date(x.get('system:time_start')).format("YYYY-MM-dd"))};
var final_Rad = ee.ImageCollection(daily_Rad_total)
.filter(ee.Filter.date(START, END))
.map(addTime)
.filter(ee.Filter.inList('Date',ee.List(DATES)));
print(final_Rad);
var ndvi = function(img){
var bands = img.select(['B2','B3','B4','B8']).multiply(0.0001)
.clip(geometry);
var index = bands.normalizedDifference(['B8','B4']);
return index
.copyProperties(img,['system:time_start','system:time_end','system:index']);
};
var S2 = ee.ImageCollection('COPERNICUS/S2_SR')
.filterBounds(geometry)
.filterDate('2018-10-24','2019-06-30')
.filter(ee.Filter.lte('CLOUDY_PIXEL_PERCENTAGE',20))
.map(ndvi);
print(S2);
var NDVI_and_Rad = S2.combine(final_Rad, false);
print(NDVI_and_Rad);
Try it here
You may use merge instead of combine to get a new image collection
var Rad1 = ee.ImageCollection('ECMWF/ERA5_LAND/HOURLY')
.filter(ee.Filter.date('2018-10-24','2019-05-20'))
.select('surface_solar_radiation_downwards');
var Rad2 = ee.ImageCollection('ECMWF/ERA5_LAND/HOURLY')
.filter(ee.Filter.date('2019-05-20','2019-06-30'))
.select('surface_solar_radiation_downwards');
var Rad1_Mj = Rad1.map(function(img){
var bands = img.multiply(0.000001);
var clip = bands.clip(geometry);
return clip
.copyProperties(img,['system:time_start','system:time_end']); });
//print(Rad1_Mj);
var Rad2_Mj = Rad2.map(function(img){
var bands = img.multiply(0.000001);
var clip = bands.clip(geometry);
return clip
.copyProperties(img,['system:time_start','system:time_end']); });
//print(Rad2_Mj);
// time frame change function for median collection
var daily_product_median = function(collection, start, count, interval, units){
var sequence = ee.List.sequence(0, ee.Number(count).subtract(1));
var origin_date = ee.Date(start);
return ee.ImageCollection(sequence.map(function(i){
var start_date = origin_date.advance(ee.Number(interval).multiply(i),units);
var end_date = origin_date.advance(ee.Number(interval).multiply(ee.Number(i).add(1)),units);
return collection.filterDate(start_date, end_date).median()
.set('system:time_start',start_date.millis())
.set('system:time_end',end_date.millis());
}))};
// daily radiation product
var daily_Rad_1 = daily_product_median(Rad1_Mj,'2018-10-24', 208 , 24 , 'hour');
// print(daily_Rad_1);
//Map.addLayer(daily_Rad_1, {min: 17.38, max: 26.07, palette : ['white','yellow','orange']}, 'Daily solar shortwave radiation 1' );
var daily_Rad_2 = daily_product_median(Rad2_Mj,'2019-05-20', 41 , 24 , 'hour');
// print(daily_Rad_2);
// Map.addLayer(daily_Rad_2, {min: 23.77, max: 26.64, palette : ['white','yellow','orange']}, 'Daily solar shortwave radiation 2');
var daily_Rad_total = daily_Rad_1.merge(daily_Rad_2);
//print(daily_Rad_total);
var START = '2018-10-24';
var END = '2019-06-30';
var DATES = [ '2018-12-19', '2018-12-29', '2019-01-23', '2019-02-12', '2019-03-04',
'2019-03-19', '2019-04-08', '2019-04-13', '2019-05-13', '2019-05-18', '2019-05-23',
'2019-05-28', '2019-06-02', '2019-06-07', '2019-06-12', '2019-06-17', '2019-06-22',
'2019-06-27'];
var addTime = function(x) {
return x.set('Date', ee.Date(x.get('system:time_start')).format("YYYY-MM-dd"))};
var final_Rad = ee.ImageCollection(daily_Rad_total)
.filter(ee.Filter.date(START, END))
.map(addTime)
.filter(ee.Filter.inList('Date',ee.List(DATES)));
print("final_Rad",final_Rad);
var ndvi = function(img){
var bands = img.select(['B2','B3','B4','B8']).multiply(0.0001)
.clip(geometry);
var index = bands.normalizedDifference(['B8','B4']);
return index
.copyProperties(img,['system:time_start','system:time_end','system:index']);
};
var S2 = ee.ImageCollection('COPERNICUS/S2_SR')
.filterBounds(geometry)
.filterDate('2018-10-24','2019-06-30')
.filter(ee.Filter.lte('CLOUDY_PIXEL_PERCENTAGE',20))
.map(ndvi);
print("S2", S2);
var NDVI_and_Rad = S2.merge(final_Rad);
print('Both image collection', NDVI_and_Rad);

Leaflet-canvas-markers cant set stroke

Leaflet-canvas-markers is extending L.circleMarker.
And therefor it should be possible to set stroke to the L.canvasMarker(?).
Does someone know what im doing wrong, or what changes i need to make in leaflet-canvas-marker package to make it work?
Here is a jsfiddle; click on the circleMarker, it gets a thicker stroke. but if you click the canvasMarker it does not get anything.
https://jsfiddle.net/tq7nf3j2/
let marker1 = L.canvasMarker([58.970471,5.730373], {
radius: 15,
img: {
url: 'img.png',
size: [30,30]
}
}).addTo(map);
marker1.on('click', function(e) {
e.target.setStyle({weight: 10})
})
Change the _updateImg(layer) function to:
_updateImg(layer) {
const { img } = layer.options;
const p = layer._point.round();
p.x += img.offset.x; p.y += img.offset.y;
if (img.rotate) {
this._ctx.save();
this._ctx.translate(p.x, p.y);
this._ctx.rotate(img.rotate * Math.PI / 180);
this._ctx.drawImage(img.el, -img.size[0] / 2, -img.size[1] / 2, img.size[0], img.size[1]);
this._ctx.restore();
} else {
if(layer.options.stroke && layer.options.weight > 0){
this._ctx.strokeStyle = layer.options.color;
this._ctx.lineWidth = layer.options.weight;
}
this._ctx.drawImage(img.el, p.x - img.size[0] / 2, p.y - img.size[1] / 2, img.size[0], img.size[1]);
if(layer.options.stroke && layer.options.weight > 0){
this._ctx.strokeRect(p.x - img.size[0] / 2, p.y - img.size[1] / 2, img.size[0], img.size[1]);
}
}
}
If you wan't that it works with rotate you have to copy it to the block above.
It's adding a rectangle with stroke behinde the image.
Also don't forgett to add weight: 0 to the image, because circleMarkers have a default stroke of 3.
let marker1 = L.canvasMarker([58.970471,5.730373], {
radius: 15,
img: {
url: 'https://register.geonorge.no/symbol/files/tilgjengelighet/sittegruppe_positiv_groenn.png',
size: [30,30]
},
weight: 0
}).addTo(map);
Example: https://jsfiddle.net/falkedesign/bLgd0opq/

How to iterate through a function each time altering the value of the parameters provided

Hi so I have a class Calculations with a series of functions one of these is keplerianElementsToEcef. In my view controller I hard code the values for the parameters and then call the function. However later on in a seperate class I have a bool isInRange. If my spacecraft is out of cellular range, I return false and a string as well. I also want to then iterate through the keplerianElementsToEcef function, each time increasing the timeOfCalculation parameter by two minutes until at some point in time in the future the satellite is in range.
I've tried to simply call the function but increase the value used initially as the time, current time, by two minutes. The other variables rangeMeanMotion etc, are the same as those hardcoded in the view controller
var isInRange: Bool
var rangeString: String
if distance < range {
isInRange = true
rangeString = "In Range"
} else {
isInRange = false
rangeString = "Not In Range"
while isInRange == false {
var dateString = dateFormatter.date(from: calculationTime!)!
var updatedDate = dateString.addingTimeInterval(TimeInterval(5.0 * 60.0))
var updateDateAsString = dateFormatter.string(from: updatedDate)
Calculations.shared.keplerianElementsToECEF(meanMotion: rangeMeanMotion, eccentricity: rangeEccentricity, Inclination: rangeInclination, LongitudeAscendingNode: rangeLongitudeAscendingNode, argumentPerigee: rangeArgumentPerigee, M0: rangeM0, epoch: rangeEpoch, date: updateDateAsString) {
}
}
}
In the function parameters under date: updateDateAsString I get the following error: Extra argument 'date' in call
var timeOfCalculation : TimeInterval = 0
func doItUntilSpacecraftIsInRange(){
repeat {
timeOfCalculation += TimeInterval(2.0 * 60.0)
Calculations.shared.keplerianElementsToECEF(meanMotion: rangeMeanMotion, eccentricity: rangeEccentricity, Inclination: rangeInclination, LongitudeAscendingNode: rangeLongitudeAscendingNode, argumentPerigee: rangeArgumentPerigee, M0: rangeM0, epoch: rangeEpoch, date: updateDateAsString)
} while spacecraft.isInRange == false
}
doItUntilSpacecraftIsInRange()
I solved this issue. I made the statement iterate during a certain time period (1 day) and my code looks like this:
else {
isInRange = false
rangeString = "Not In Range"
print(calculationTime)
if let calcTime = calculationTime {
let parsedDate = dateFormatter.date(from: calcTime) ?? Date()
for interval in stride(from: 0, to: 1440, by: 2) {
var updatedDate = parsedDate.addingTimeInterval(TimeInterval(interval * 60))
var updateDateAsString = dateFormatter.string(from: updatedDate)
Calculations.shared.keplerianElementsToECEF(meanMotion: rangeMeanMotion, eccentricity: rangeEccentricity, Inclination: rangeInclination, LongitudeAscendingNode: rangeLongitudeAscendingNode, argumentPerigee: rangeArgumentPerigee, M0: rangeM0, epoch: rangeEpoch, date: updateDateAsString)
let xDistance = ecefX - wgs84X
let yDistance = ecefY - wgs84Y
let zDistance = ecefZ - wgs84Z
let iteratedDistance = sqrt(xDistance*xDistance + yDistance*yDistance + zDistance*zDistance)
if iteratedDistance < 7000 {
nextVisible = updateDateAsString
break
}
}
}
}

Why does this SwiftCharts line chart jump when starting to pan to the right

I'm creating a chart using SwiftCharts based on the Trendline example provided with the library. In my application, I'm charting weight lifting events showing the single highest lift weight on each distinct day. In my example, I'm charting 4 Bench Press events.
The chart renders when the view controller is first displayed, but when I pan to the right it stutters, spreads out, and the points move. This is what that looks like:
Note that when the chart is first rendered, the lowest plotted value (208.0) appears to be between Mar 12 and Mar 13, yet after it does that stutter thing, the point moves to the right of Mar 13.
The chartPoints being plotted are:
▿ 4 elements
▿ 0 : Mar 12, 239.17
▿ 1 : Mar 13, 208
▿ 2 : Mar 15, 267.17
▿ 3 : Mar 18, 240
Here's the view controller:
import UIKit
import SwiftCharts
class ChartViewController: UIViewController {
fileprivate var chart: Chart? // arc
fileprivate let dataManager = CoreDataHelper()
override func viewDidLoad() {
super.viewDidLoad()
let labelSettings = ChartLabelSettings(font: ChartDefaults.labelFont)
let liftEventTypeUuid = "98608870-E3CE-476A-B1E4-018D2AE4BDBF"
let liftEvents = dataManager.fetchLiftsEventsOfType(liftEventTypeUuid)
let dailyLiftEvents = liftEvents.reduce(into: [Date:[LiftEvent]](), { dailyLiftEvents, currentLiftEvent in
dailyLiftEvents[Calendar.current.startOfDay(for: currentLiftEvent.date), default: [LiftEvent]()].append(currentLiftEvent)
})
let dailyMaxLiftEvents = dailyLiftEvents.map({$0.value.max(by: {$0.oneRepMax < $1.oneRepMax})})
var sortedLiftEvents = dailyMaxLiftEvents.sorted(by: { $0?.date.compare(($1?.date)!) == .orderedAscending })
var readFormatter = DateFormatter()
readFormatter.dateFormat = "dd.MM.yyyy"
var displayFormatter = DateFormatter()
displayFormatter.dateFormat = "MMM dd"
let date = {(str: String) -> Date in
return readFormatter.date(from: str)!
}
let calendar = Calendar.current
let dateWithComponents = {(day: Int, month: Int, year: Int) -> Date in
var components = DateComponents()
components.day = day
components.month = month
components.year = year
return calendar.date(from: components)!
}
func filler(_ date: Date) -> ChartAxisValueDate {
let filler = ChartAxisValueDate(date: date, formatter: displayFormatter)
filler.hidden = true
return filler
}
let chartPoints = sortedLiftEvents.map { ChartPoint(x: ChartAxisValueDate(date: ($0?.date)!, formatter: displayFormatter), y: ChartAxisValueDouble(($0?.calculateOneRepMax().value)!)) }
let highestWeight = sortedLiftEvents.last??.oneRepMax.value
let lowestWeight = sortedLiftEvents.first??.oneRepMax.value
let yValues = stride(from: roundToTen(x: lowestWeight! - 40), through: roundToTen(x: highestWeight! + 40), by: 20).map {ChartAxisValueDouble(Double($0), labelSettings: labelSettings)}
let xGeneratorDate = ChartAxisValuesGeneratorDate(unit: .day, preferredDividers: 2, minSpace: 1, maxTextSize: 12)
let xLabelGeneratorDate = ChartAxisLabelsGeneratorDate(labelSettings: labelSettings, formatter: displayFormatter)
let firstDate = sortedLiftEvents.first??.date
let lastDate = sortedLiftEvents.last??.date
let xModel = ChartAxisModel(firstModelValue: (firstDate?.timeIntervalSince1970)!, lastModelValue: (lastDate?.timeIntervalSince1970)!, axisTitleLabels: [ChartAxisLabel(text: "Date", settings: labelSettings)], axisValuesGenerator: xGeneratorDate, labelsGenerator: xLabelGeneratorDate)
let yModel = ChartAxisModel(axisValues: yValues, axisTitleLabel: ChartAxisLabel(text: "1-RM", settings: labelSettings.defaultVertical()))
let chartFrame = ChartDefaults.chartFrame(view.bounds)
var chartSettings = ChartDefaults.chartSettingsWithPanZoom // was ChartDefaults.chartSettings
chartSettings.trailing = 80
// Set a fixed (horizontal) scrollable area 2x than the original width, with zooming disabled.
chartSettings.zoomPan.maxZoomX = 2
chartSettings.zoomPan.minZoomX = 2
chartSettings.zoomPan.minZoomY = 1
chartSettings.zoomPan.maxZoomY = 1
ChartAxisValuesStaticGenerator.generateYAxisValuesWithChartPoints(chartPoints, minSegmentCount: 10, maxSegmentCount: 20, multiple: 2, axisValueGenerator: {ChartAxisValueDouble($0, labelSettings: labelSettings)}, addPaddingSegmentIfEdge: false)
let lineModel = ChartLineModel(chartPoints: chartPoints, lineColor: UIColor.red, lineCap: .round ,animDuration: 1, animDelay: 0)
let trendLineModel = ChartLineModel(chartPoints: TrendlineGenerator.trendline(chartPoints), lineColor: UIColor.blue, animDuration: 0.5, animDelay: 1)
let coordsSpace = ChartCoordsSpaceLeftBottomSingleAxis(chartSettings: chartSettings, chartFrame: chartFrame, xModel: xModel, yModel: yModel)
let (xAxisLayer, yAxisLayer, innerFrame) = (coordsSpace.xAxisLayer, coordsSpace.yAxisLayer, coordsSpace.chartInnerFrame)
let chartPointsLineLayer = ChartPointsLineLayer(xAxis: xAxisLayer.axis, yAxis: yAxisLayer.axis, lineModels: [lineModel])
let trendLineLayer = ChartPointsLineLayer(xAxis: xAxisLayer.axis, yAxis: yAxisLayer.axis, lineModels: [trendLineModel])
let settings = ChartGuideLinesDottedLayerSettings(linesColor: UIColor.black, linesWidth: ChartDefaults.guidelinesWidth)
let guidelinesLayer = ChartGuideLinesDottedLayer(xAxisLayer: xAxisLayer, yAxisLayer: yAxisLayer, settings: settings)
let chart = Chart(
frame: chartFrame,
innerFrame: innerFrame,
settings: chartSettings,
layers: [
xAxisLayer,
yAxisLayer,
guidelinesLayer,
chartPointsLineLayer,
trendLineLayer
]
)
view.addSubview(chart.view)
self.chart = chart
}
private struct liftWeightItem {
let number: Int
let text: String
init(number: Int, text: String) {
self.number = number
self.text = text
}
}
private struct liftDateItem {
let name: String
let quantity: liftWeightItem
init(name: String, quantity: liftWeightItem) {
self.name = name
self.quantity = quantity
}
}
func createChartPoint(dateStr: String, percent: Double, readFormatter: DateFormatter, displayFormatter: DateFormatter) -> ChartPoint {
return ChartPoint(x: createDateAxisValue(dateStr, readFormatter: readFormatter, displayFormatter: displayFormatter), y: ChartAxisValueDouble(percent))
}
func createDateAxisValue(_ dateStr: String, readFormatter: DateFormatter, displayFormatter: DateFormatter) -> ChartAxisValue {
let date = readFormatter.date(from: dateStr)!
let labelSettings = ChartLabelSettings(font: ChartDefaults.labelFont, rotation: 45, rotationKeep: .top)
return ChartAxisValueDate(date: date, formatter: displayFormatter, labelSettings: labelSettings)
}
func roundToTen(x : Double) -> Int {
return 10 * Int(round(x / 10.0))
}
class ChartAxisValuePercent: ChartAxisValueDouble {
override var description: String {
return "\(formatter.string(from: NSNumber(value: scalar))!)%"
}
}
}
My suspicion is that it has something to do with the rendering of the x-axis so I've tried adjusting the preferredDividers and minSpace values:
let xGeneratorDate = ChartAxisValuesGeneratorDate(unit: .day, preferredDividers: 2, minSpace: 1, maxTextSize: 12)
but that not only doesn't fix the problem, it results in a new one I'll post about separately.
I've read through the documentation several times but I still haven't been able to figure it out. This is a beautifully written library so I'd really like to be able to use it. Any help is greatly appreciated.

Find Difference between the two sequence of points value in AmCharts?

I am using the AmCharts. I need to display value in the balloon text , that value is not a value field.
For example : X axis Value 0 , Y axis 1, (0,1) is 2 ; (1,2) is 5.
I need to display the Difference between the values (0,1) and (1,2) - that means "3" as Balloon in the point (1,2). Any ideas ?
Yes, the chart on your screenshot is possible to implement.
At first, add additional fields to your chart data, for example, labelGraph1, labelGraph2. Then you can use the labelText property of the AmCharts.AmGraph object.
var chartData = [{
title: "Apples",
value1: 24,
value2: 28,
labelGraph1: null,
labelGraph2: null
}, {
title: "Bananas",
value1: 27,
value2: 31,
labelGraph1: null,
labelGraph2: null
}, {
title: "Cherries",
value1: 27,
value2: 39,
labelGraph1: null,
labelGraph2: null
}];
for(var i = 0; i < chartData.length; i++) {
chartData[i].labelGraph1 = chartData[i].value1;
chartData[i].labelGraph2 = chartData[i].value2 - chartData[i].value1;
}
var chart;
AmCharts.ready(function () {
// SERIAL CHART
chart = new AmCharts.AmSerialChart();
chart.dataProvider = chartData;
chart.categoryField = "title";
// GRAPHS
var graph1 = new AmCharts.AmGraph();
graph1.valueField = "value1";
graph1.type = "line";
graph1.fillAlphas = 0.6;
graph1.labelText = "[[labelGraph1]]";
chart.addGraph(graph1);
var graph2 = new AmCharts.AmGraph();
graph2.valueField = "value2";
graph2.type = "line";
graph2.fillAlphas = 0.6;
graph2.labelText = "[[labelGraph2]]";
chart.addGraph(graph2);
// WRITE
chart.write("chartdiv")
});
The only one difficulty is to calculate values of the displayed fields.
I did it so, and you should change that function according to your data:
for(var i = 0; i < chartData.length; i++) {
chartData[i].labelGraph1 = chartData[i].value1;
chartData[i].labelGraph2 = chartData[i].value2 - chartData[i].value1;
}