is CoreData a good choice for me ?

i would have only one entity with maybe 20 attributes but i would create new entry every second for 8 to 10 of hours a day, over many days.


The reason I think about using core data if for graph, I would be nice to let the user select the attribute and timeframe, then graphs it


i currently save the data into a tab separated files but I don't want to dig into the file for each graph request.

Accepted Reply

You can definitely use core data. But I'd run some performace tests before deciding. Create a UNIT test which will simulate one year worth of data and try to draw a graph. My guess is that you will need to implement some summarization - like another entity which will represent one day's data summary. How exactly this can work depends on your data model.


I did something simmilar for my app. I have to say core data performance on iPhone surprised me in a positive way.

Replies

You can definitely use core data. But I'd run some performace tests before deciding. Create a UNIT test which will simulate one year worth of data and try to draw a graph. My guess is that you will need to implement some summarization - like another entity which will represent one day's data summary. How exactly this can work depends on your data model.


I did something simmilar for my app. I have to say core data performance on iPhone surprised me in a positive way.

Thank you.



I will offer the user to average data , for example, every 5 seconds or something like data

i wish i could create entity without puting it into the context, to keep it around until i ahve the number i need to average and then discard it wihtout having to remove them from coredata, I might use other var to do that for now.


i also created an option to erese all data in coredata


and i show filesize to help the user decide


one day I hope to offer Export to file before erasing


I dont like to use opensource package but I might do it to graph the data because I dont have much time for this app.

A great library for graphs is this one:


https://github.com/danielgindi/Charts

Great !!

thank you.