# Basic documentation for pySatData
Most functions' structure and some loaders are from the pySPEDAS (https://github.com/spedas/pyspedas) repository. I just used and organized it in a way that I felt was more accessible for my purposes :). There is an option to store the variables in a pandas DataFrame format or pytplot format.
## Requirements
Python 3.8+
### Installation:
```
conda create -n yourenvname python=x.x anaconda
conda activate yourenvname
pip install pysatdata
```
***
## config_file.json
It can be done in this file if some change in downloading directories is needed.
```pysatdata/resources/config_file.json```
This file sets the HTTP directory for downloading data and the local directory to save the downloaded data.
The local directory files are organized as http directory, i.e.:
* RBSP: HOME/sat_data/rbsp/rbspa/l2/ect/rept/sectors/rel03/YYYY/filename.cdf
This files handles with the different http subpaths for the different levels and intruments in each probe.
***
## Examples: Loading data.
### RBSP REPT data
```python
#Import the loading functions.
from pysatdata.loaders.load import *
# Define the time range for downloading data.
trange=['2021-05-26', '2021-05-30']
# Loading Van Allen probes REPT data.
varss_rept = load_sat(trange=trange, satellite="rbsp",
probe=['a', 'b'], level="3",
rel="rel03", instrument="rept",
datatype="sectors",
downloadonly=False,
searchFilesFirst=True,
usePandas=False,
usePyTplot=True)
```
### RBSP EMFISIS data.
```python
varss_emfisis = load_sat(trange=trange, satellite="rbsp",
probe=['a','b'], rel="rel03", level="3",
instrument="emfisis", datatype="magnetometer",
cadence="1sec", coord="gse",
varnames=[], downloadonly=False,
usePandas=True, usePyTplot=False)
```
### RBSP MAGEIS data.
```python
varss_mageis = load_sat(trange=trange, satellite="rbsp",
probe=['a','b'], level="3",
rel="rel03", instrument="mageis",
datatype="sectors",
downloadonly=False,
usePandas=False, usePyTplot=True)
```
### RBSP EFW data.
```python
varss_efw = load_sat(trange=trange, satellite="rbps",
probe=['a','b'], level="2", rel='rel03',
instrument="efw", datatype="esvy_despun",
varnames=['efield_mgse', 'lshell'], downloadonly=False,
usePandas=False, usePyTplot=True)
```
### OMNI Solar wind data
```python
varss_omni = load_sat(trange=trange, satellite="omni",
probe="omni"
instrument="omni_cdaweb",datatype="hro_1min",
downloadonly=False,
usePandas=False, usePyTplot=True)
```
See ```plot_interpFlux_RBSP.py``` for an example of plotting the interpolated electron flux.
Raw data
{
"_id": null,
"home_page": "https://github.com/zemarchezi/pySatData",
"name": "pysatdata",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.6",
"maintainer_email": "",
"keywords": "satellite space data tools",
"author": "Jose Paulo Marchezi",
"author_email": "jose.marchezi@inpe.br, jpmarchezi@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/64/ab/1433796abab89c44d47d48b43e7e5f19a93f81a8abe5f31e45bb8f98120b/pysatdata-1.0.12.tar.gz",
"platform": null,
"description": "# Basic documentation for pySatData\n\nMost functions' structure and some loaders are from the pySPEDAS (https://github.com/spedas/pyspedas) repository. I just used and organized it in a way that I felt was more accessible for my purposes :). There is an option to store the variables in a pandas DataFrame format or pytplot format.\n\n## Requirements\n\nPython 3.8+\n### Installation: \n```\nconda create -n yourenvname python=x.x anaconda\nconda activate yourenvname\n\npip install pysatdata\n```\n\n***\n## config_file.json\n\nIt can be done in this file if some change in downloading directories is needed.\n\n```pysatdata/resources/config_file.json```\n\nThis file sets the HTTP directory for downloading data and the local directory to save the downloaded data.\n\nThe local directory files are organized as http directory, i.e.:\n* RBSP: HOME/sat_data/rbsp/rbspa/l2/ect/rept/sectors/rel03/YYYY/filename.cdf\n\nThis files handles with the different http subpaths for the different levels and intruments in each probe.\n\n***\n\n## Examples: Loading data.\n\n### RBSP REPT data\n```python\n#Import the loading functions.\nfrom pysatdata.loaders.load import *\n\n# Define the time range for downloading data.\ntrange=['2021-05-26', '2021-05-30']\n\n# Loading Van Allen probes REPT data.\nvarss_rept = load_sat(trange=trange, satellite=\"rbsp\",\n probe=['a', 'b'], level=\"3\", \n rel=\"rel03\", instrument=\"rept\",\n datatype=\"sectors\",\n downloadonly=False, \n searchFilesFirst=True,\n usePandas=False,\n usePyTplot=True)\n```\n### RBSP EMFISIS data.\n\n```python\nvarss_emfisis = load_sat(trange=trange, satellite=\"rbsp\",\n probe=['a','b'], rel=\"rel03\", level=\"3\",\n instrument=\"emfisis\", datatype=\"magnetometer\",\n cadence=\"1sec\", coord=\"gse\",\n varnames=[], downloadonly=False,\n usePandas=True, usePyTplot=False)\n```\n\n### RBSP MAGEIS data.\n\n```python\nvarss_mageis = load_sat(trange=trange, satellite=\"rbsp\",\n probe=['a','b'], level=\"3\", \n rel=\"rel03\", instrument=\"mageis\",\n datatype=\"sectors\",\n downloadonly=False, \n usePandas=False, usePyTplot=True)\n```\n### RBSP EFW data.\n\n```python\nvarss_efw = load_sat(trange=trange, satellite=\"rbps\",\n probe=['a','b'], level=\"2\", rel='rel03',\n instrument=\"efw\", datatype=\"esvy_despun\",\n varnames=['efield_mgse', 'lshell'], downloadonly=False,\n usePandas=False, usePyTplot=True)\n```\n\n### OMNI Solar wind data\n\n```python\nvarss_omni = load_sat(trange=trange, satellite=\"omni\",\n probe=\"omni\"\n instrument=\"omni_cdaweb\",datatype=\"hro_1min\",\n downloadonly=False,\n usePandas=False, usePyTplot=True)\n```\n\nSee ```plot_interpFlux_RBSP.py``` for an example of plotting the interpolated electron flux.\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Python Space Physics Satellite Data Analysis Toolkit",
"version": "1.0.12",
"project_urls": {
"Homepage": "https://github.com/zemarchezi/pySatData"
},
"split_keywords": [
"satellite",
"space",
"data",
"tools"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "827567a5dfe31c23e59fbd34cca556339e2f7ff6398898c2b3f36afbf6bab24a",
"md5": "986df08f0ed844b7233a5c79e7d49ebb",
"sha256": "ec46816ab73be8d89ff5df568098d2a10d762fe3d936992a015482eb6a955e25"
},
"downloads": -1,
"filename": "pysatdata-1.0.12-py3-none-any.whl",
"has_sig": false,
"md5_digest": "986df08f0ed844b7233a5c79e7d49ebb",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.6",
"size": 69063,
"upload_time": "2024-01-31T20:24:02",
"upload_time_iso_8601": "2024-01-31T20:24:02.049879Z",
"url": "https://files.pythonhosted.org/packages/82/75/67a5dfe31c23e59fbd34cca556339e2f7ff6398898c2b3f36afbf6bab24a/pysatdata-1.0.12-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "64ab1433796abab89c44d47d48b43e7e5f19a93f81a8abe5f31e45bb8f98120b",
"md5": "075ae98f6d7534b63fc67734fd4146a1",
"sha256": "c6387bcbdf1255c0576575749de5760a8d353440600e1a54daa2f92884c527cb"
},
"downloads": -1,
"filename": "pysatdata-1.0.12.tar.gz",
"has_sig": false,
"md5_digest": "075ae98f6d7534b63fc67734fd4146a1",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.6",
"size": 56540,
"upload_time": "2024-01-31T20:24:03",
"upload_time_iso_8601": "2024-01-31T20:24:03.489157Z",
"url": "https://files.pythonhosted.org/packages/64/ab/1433796abab89c44d47d48b43e7e5f19a93f81a8abe5f31e45bb8f98120b/pysatdata-1.0.12.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-01-31 20:24:03",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "zemarchezi",
"github_project": "pySatData",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "pysatdata"
}