When dealing with a large number of data points, is an array of objects a poor choice to use? Is it inefficient to perform lookups when the data is in this format?
var list = [
{ date: '12/1/2011', reading: 3, id: 20055 },
{ date: '13/1/2011', reading: 5, id: 20053 },
{ date: '14/1/2011', reading: 6, id: 45652 }
];
Would it be more efficient to have it in the form of a unifying hash table?
var dict = {
Item 1: {date: '12/1/2011', reading: 3, id: 20055 },
Item 2: {date: '13/1/2011', reading: 5, id: 20053 },
Item 3: {date: '14/1/2011', reading: 6, id: 45652 }
};