Skip to main content
File added late

1 file was added to this release more than 14 days after its initial publication. Inspect the release files before installing.

Data_Box

This project is to clean factor data and to prepare for back test.

Dependencies

  • python 3.5

  • pandas 0.22.0

  • numpy 1.14.3

  • pickle

  • sklearn 0.19.1 (for pca only)

Example

from data_box import data_box

db=data_box()\
    .set_lag(freq='d',day_lag=0)\
    .load_adjPrice(price)\ # 'price' is a pd.DataFrame with dates(20190101 int type) as its index and tickers as its column
    .load_indestry(ind)\
    .load_suspend(sus)\
    .load_indexWeight(index_weight)\
    .calc_indweight()\ # calculate industry weight based on index weight and stocks' industry in this index
    .load_cap(cap)\
    .add_factor('f1',factor1)\
    .add_factor('f2',factor2)\
    .add_factor('f3',factor3)\
    .align_data()\
    .factor_pca()\
    .factor_ind_neutral()\
    .factor_size_neutral()\
    .factor_zscore()

print(db.Factor)
print(db.Price)
print(db.Sus)
print(db.Cap)

# save and reload
db.save(path)
db2=databox().load(path)

Metadata

Release files for data-box 0.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

File added late

1 file was uploaded more than 14 days after the first file in this release.

While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.

We recommend inspecting the release files before installing.

Source distribution (sdist)

Source distribution for data-box 0.0.1
File Size Uploaded Provenance
data_box-0.0.1.tar.gz 5.7 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for data-box 0.0.1
File Interpreter ABI Platform
data_box-0.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 13.3 kB

Release files / data_box-0.0.1.tar.gz

File added late

This file was uploaded more than 14 days after the first file in this release.

While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.

We recommend inspecting the release file before installing.

Download URL data_box-0.0.1.tar.gz
Size 5.7 kB
Tags Source
SHA-256 checksum
How to use checksums
a84211522f8e482f6e4e57304669cc978bbb0dd0d5643f5138a76caf33a18691
BLAKE2b-256 checksum
How to use checksums
d8d3be4978738bfa3d5aecad0a3d4bb9f3166f0ab52e9f7252af2d8a5a5b2467
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.11.0 pkginfo/1.4.2 requests/2.14.2 setuptools/40.2.0 requests-toolbelt/0.8.0 tqdm/4.23.4 CPython/3.5.5

Release files / data_box-0.0.1-py3-none-any.whl

Download URL data_box-0.0.1-py3-none-any.whl
Size 7.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5c88a3f47917067c2aa260c4a873e7a10433c73795e78acd3997304a440214e7
BLAKE2b-256 checksum
How to use checksums
3cbafc75ff4429ad36d0e4a40c799a6bf6f529835d3ece2ad1f95c8bb563dc2c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.11.0 pkginfo/1.4.2 requests/2.14.2 setuptools/40.2.0 requests-toolbelt/0.8.0 tqdm/4.23.4 CPython/3.5.5

Security for data-box 0.0.1

Upload timing

File added late

1 file was uploaded more than 14 days after the first file in this release.

While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.


Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page