nilmtk / nilmtk

Non-Intrusive Load Monitoring Toolkit (nilmtk)
http://nilmtk.github.io
Apache License 2.0
822 stars 459 forks source link

Testing meters_correlation function #252

Open nipunbatra opened 9 years ago

nipunbatra commented 9 years ago

Issue describing the meters_correlation function: https://github.com/nilmtk/nilmtk/issues/160 Source can be found here: https://github.com/nilmtk/nilmtk/blob/master/nilmtk/metergroup.py and correlation_with method in https://github.com/nilmtk/nilmtk/blob/master/nilmtk/elecmeter.py

Both of these functions need test code. This test functions can be modeled on existing test functions here: https://github.com/nilmtk/nilmtk/blob/master/nilmtk/tests/test_metergroup.py

Procedure would be as follows:

  1. Create a test data set, say of 4 meters, or use an existing test datastore (should be small enough to fit in memory)
  2. Use existing Pandas functions for finding correlation
  3. Compute correlation between few pairs of meters using Pandas and compare with the correlation_with method
  4. Compute correlation matrix (correlation between all possible pairs of meters) and compare the output with meters_correlation function.
nipunbatra commented 9 years ago

@RishiBaijal is assigned.