Metadata-Version: 2.1
Name: cxcsvtopandas
Version: 0.1.3
Summary: A simple example package
Home-page: https://github.com/amitgupta7/my_package
Author: Amit Gupta
Author-email: amitgupta@example.com
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.6
Description-Content-Type: text/markdown
Requires-Dist: pandas==2.2.2
Requires-Dist: plotly==5.22.0

# cxpandascsvloader
A simple example package for loading and processing CSV data into Pandas DataFrames.

## Installation
You can install the `cxpandascsvloader` package using pip:

```sh
pip install cxcsvtopandas
```

## Usage
```sh
% python                        
Python 3.9.20 (main, Oct 19 2024, 17:36:14) 
[Clang 15.0.0 (clang-1500.3.9.4)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import cxcsvtopandas.dataframeloader as dfl
>>> dfl.printinfo()
dataframeloader module loaded.
```

## Examples
Using the generic `dataframeloader` method to read files with specific prefix.
```python
import cxcsvtopandas.dataframeloader as dfl
root = '../../.dataDir'
df = dfl.loadDataFrameFromFileRegex(root, "ASSESS*")
```

Optionally specify date range for filtering csv files;
```python
import cxcsvtopandas.dataframeloader as dfl
root = '../../.dataDir'
fromDt = '2024-11-10'
toDt = '2024-12-10'
df = dfl.loadDataFrameFromFileRegex(root, "ASSESS*", daterange=[fromDt, toDt])
```

Propritary timeseries reporting;
```python
import cxcsvtopandas.dataframeloader as dfl
root = '../../.dataDir'
fromDt = '2024-11-10'
toDt = '2024-12-10'
metricsArr = ['cpu_used','task_queue_length', 'memory_used']
daterange=[fromDt, toDt]
df = dfl.loadApplianceTimeSeriesData(root, metricsArr, daterange)
appliance_id='58e98e10-1b19-4c84-93c0-db2ad5903b80'
## fromDt and toDt can also be a subset of the total dataframe.
fig  = dfl.plotMetricsFacetForApplianceId(df, appliance_id)
fig.show()
```
