began to add chart history function