carissalow / rapids

Reproducible Analysis Pipeline for Data Streams
http://www.rapids.science/
GNU Affero General Public License v3.0
36 stars 20 forks source link

Remove warning from readable_datetime.R #203

Closed JulioV closed 1 year ago

JulioV commented 1 year ago

A comment in this thread reported the following warning:

Warning message:
  The following named parsers don't match the column names: local_date_time, local_start_date_time, local_end_date_time

This happens because those columns appear in the col specification of read_csv_chunked here but such columns only exist for Fitbit data and not for phone sensors.

We load those columns as character because we convert them to date time with a specific time zone in this function. Thus, to avoid that warning we should pass cols() to col_types when device_type is not Fitbit and cols(local_date_time = col_character(), local_start_date_time = col_character(), local_end_date_time = col_character()) when it is Fitbit.

@jenniferfedor Can we implement this improvement in our next release please?

jenniferfedor commented 1 year ago

Hi @JulioV, sure thing. It looks like local_start_date_time and local_end_date_time are only present in Fitbit sleep summary data, so if we pass cols(local_date_time = col_character(), local_start_date_time = col_character(), local_end_date_time = col_character()) to col_types when the device type is Fitbit, the following warning message is still produced during rule fitbit_readable_datetime for all other Fitbit data types:

Warning message:
The following named parsers don't match the column names: local_start_date_time, local_end_date_time 

To resolve all warning messages, I think we can:

I just opened a pull request (#205) to address this issue. Could you please review whenever you have some time and let me know if you'd like me to make any changes? Thank you!

JulioV commented 1 year ago

Good catch, yes, thank you!