JSON graph
Hello, I am using data located in a JSON file to create a graph.
In the below example, I pull a temperature # for the month of "Jan".
I would like to replace "Jan" by the current layer's name or better, by the name of the layer right below, to which I would add +1.
I have tried thisComp.layer(index).name with no luck.
eval("var variable="+footage("exportedxls.json").sourceText);
hauteur = variable[0].Jan;
min = thisComp.layer("Slider Controls").effect("Min")("Slider");
max = thisComp.layer("Slider Controls").effect("Max")("Slider");
max_movement = -thisComp.layer("Slider Controls").effect("Max Movement")("Slider")
newBaseline = thisComp.layer("Slider Controls").effect("New Baseline")("Slider");
myYheight = ((hauteur - min) / max) * max_movement + newBaseline;
myXspace = thisComp.layer(index+1).transform.position[0]+thisComp.layer("Slider Controls").effect("Space btw points")("Slider");
[myXspace, myYheight]
Would anyone be able to help me out?
Thank you,
Alex
