You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm new to Jupyter and pixiedust and I'm having a hardtime on my first experiments with it.
I'm looping through an array to recover values by time stamp and put them in a new array to be displayed as a line graph.
var data = [];
body.donors.forEach(
function(donor) {
var epochDate = new Date(donor.data_envio).setHours(0,0,0,0);
var obj = {
date: new Date(epochDate),
valor: Number(donor.valor)
};
data.push(obj);
}
);
display(data);
When I do this, the generated chart says "x must be a label or position".
Opening "Options", the date field is shown as "string".
I've tried formating the date field as ISO 8601 but it is still understood as string.
I've found no information/documentation on how to "cast" my data so that pixiedust correctly understands it.
The text was updated successfully, but these errors were encountered:
pachecolp
changed the title
How do I convert a values so that they are correctly understood by display()?
How do I convert an array of values so that they are correctly understood by display()?
Jun 10, 2018
I'm new to Jupyter and pixiedust and I'm having a hardtime on my first experiments with it.
I'm looping through an array to recover values by time stamp and put them in a new array to be displayed as a line graph.
When I do this, the generated chart says "x must be a label or position".
Opening "Options", the
date
field is shown as "string".I've tried formating the
date
field as ISO 8601 but it is still understood as string.I've found no information/documentation on how to "cast" my data so that pixiedust correctly understands it.
The text was updated successfully, but these errors were encountered: