var Bar = function(){
}
Bar.prototype.drawBar = function(obj){
}
var bars = [];// Creating array
for (i = 0;i < ar.length ;i++){
bars[i] = [new Bar(ar[i],i)]; // Creating array of objects
bars[i].drawBar(i);// I am looking for something like this, Currently it doesn't work
}
I have something like this, How do I draw a bar, giving a reference/index, It should draw with the measurements
bars[i] = new Bar(ar[i],i);. Or do you really want an array of arrays?