Export data to excel readable format from timestore feed?

Hi,

Is it possible to export data to excel readable format (csv, xml, etc) from a timestore feed?

 

Thanks for your help!

TrystanLea's picture

Re: Export data to excel readable format from timestore feed?

Hello Jostor, its not a feature thats implemented yet, apart from the usual data request api that returns a json string of 1000 datapoints between a start and end time.

But it would be fairly straightforward to implement something like this, Id like to create a set of tools for exporting/importing feeds in different formats at somepoint. Do you just want to export the whole feed as csv or parts of it and at different average levels? ie daily average

 

jostor's picture

Re: Export data to excel readable format from timestore feed?

Hi Trystan,

Thanks for your reply! 

To begin with, it would be nice to just export the whole feed as csv. But I also think it would have been very useful to have a "Download data" button next to the graph views. When you press this button you will download the data from the same interval that is displayed in the graph.

Another solution would be to have a page where you can specify the feed, and the interval you want to download data from.

These are just my thoughts on the subject. Maybe you or someone else have better ideas?

palonenlabs's picture

Re: Export data to excel readable format from timestore feed?

Hello

This feature would be very useful for us too. Our local university is interested to have our power Electric Vehicle consumption measurements. We have a local installation of emoncms with timestore formatted database and would very much like to have our measurements exported as a CSV. Then we could just send that CSV-file to university as needed.  For us it would be sufficient to have just raw feed values exported to a file (for example csv) along with a timestamp for each value.

With very best regards,

Henry Palonen

 

XaroRSA's picture

Re: Export data to excel readable format from timestore feed?

I have made this module will upload code later today.

XaroRSA's picture

Re: Export data to excel readable format from timestore feed?

https://github.com/XaroRSA/DataDownload/tree/master

Very simple module, will add more in time, right now doing a EmonTX board running NRF24L01+ wireless.

Eric_AMANN's picture

Re: Export data to excel readable format from timestore feed?

Hi,

I installed this module on my local EmonCMS server (Linux EmonCMS V7).

I got the following message when cliking on the "Data Download" tab:

Warning: Missing argument 2 for Feed::__construct(), called in /var/www/emoncms/Modules/DataDownload/DataDownload_controller.php on line 10 and defined in /var/www/emoncms/Modules/feed/feed_model.php on line 28 Warning: Missing argument 3 for Feed::__construct(), called in /var/www/emoncms/Modules/DataDownload/DataDownload_controller.php on line 10 and defined in /var/www/emoncms/Modules/feed/feed_model.php on line 28 Notice: Undefined variable: timestore_adminkey in /var/www/emoncms/Modules/feed/feed_model.php on line 43 Notice: Undefined variable: redis in /var/www/emoncms/Modules/feed/feed_model.php on line 51 Warning: Missing argument 3 for Input::__construct(), called in /var/www/emoncms/Modules/DataDownload/DataDownload_controller.php on line 13 and defined in /var/www/emoncms/Modules/input/input_model.php on line 21 Notice: Undefined variable: feed in /var/www/emoncms/Modules/input/input_model.php on line 24 Fatal error: Call to undefined method Feed::sAdd() in /var/www/emoncms/Modules/input/input_model.php on line 390

 

Any idea ?

 

XaroRSA's picture

Re: Export data to excel readable format from timestore feed?

Yeah no ways that module gonna work on V7 of emoncms. Im still running V5 and the module has not been adapted for these new storage methods.

I will upload the completed modules soon.

Eric_AMANN's picture

Re: Export data to excel readable format from timestore feed?

It would be great if it can work on EmonCMS 7

Many thanks !

kaulquappe's picture

Re: Export data to excel readable format from timestore feed?

hi,

quite an old thread, but acuatlly I'm asking myself the same question. I'm running emoncms on a private server and would love to export the Data to an openoffice calc file...or xls...

is there a chance to do that?

 

fubar's picture

Re: Export data to excel readable format from timestore feed?

 I'm running emoncms on a private server and would love to export the Data to an openoffice calc file...or xls...

If you're happy working on the pi command line with python (ie not built in to emoncms), https://github.com/fubar2/emonpi_py/blob/master/readrawemoncms.py will convert the php binary data at the path specified (FROM_DIR = '/home/pi/data/phpfina/') into tabular data which excel will usually open without any fuss. 

I've also got a simple paho based client which writes a tabular file containing the records from an mqtt subscription at https://github.com/fubar2/emonpi_py/blob/master/mqtt_emon.py to collect ongoing data.

Suggestions for improvement welcomed 

TrystanLea's picture

Re: Export data to excel readable format from timestore feed?

Not sure if it will work with timestore but if you are after a tool for exporting data in a emoncms graph view to CSV with options for time formats and what to do about missing data, the new data viewer module I posted yesterday may help https://openenergymonitor.org/emon/node/12280

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.