graph function using real data
fixed indexed not binding properly
put example back ready for demo