Skip to main content

A generic pricefeed generator with configurable deliveries and statistical info on prices generated.

Project description

PriceFeed

This is a generator for random price feeds that can be used to generate a new price at will or at predefined time intervals. The PriceFeed object will also maintain statistics on all the prices that it generated.

A typical use-case is in a development environment where you would like to mimic a pricefeed.

You can install the package via PyPI or from source.

Install from PyPI

pip install pricefeed

Install from Source (GitHub)

git clone https://github.com/smart-t/pricefeed.git
cd pricefeed
pip install .

Example: How to use this package

import pricefeed as pf

AAPL_ticker = pf.Pricefeed("AAPL", 235.0, 500, 0.001)
for i in range(10):
  print(f"{i} : {next(AAPL_ticker)}")

The above script will generate a new price every 500 miliseconds and completes a list with 10 simulated 'AAPL' stock prices starting at $235.0. The 4th argument is used to indicate how volatile the stock movement will be.

The generated prices are designed to stay relatively close to the given start price.

Contributions

This is an opensource project where you are invited to contribute and help evolve the pricefeed as we go.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pricefeed-0.1.0.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pricefeed-0.1.0-py3-none-any.whl (3.8 kB view details)

Uploaded Python 3

File details

Details for the file pricefeed-0.1.0.tar.gz.

File metadata

  • Download URL: pricefeed-0.1.0.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for pricefeed-0.1.0.tar.gz
Algorithm Hash digest
SHA256 5e229dea609ac0192fa0a6a4e3f9d9af40f98fe2e0cdd577d2a60401affdda56
MD5 03566d4132422e02d96ac5fe140e79f3
BLAKE2b-256 973786abddb3e42cb3dda3c429ed69970654b717b6966266d91e6f41415d7e34

See more details on using hashes here.

File details

Details for the file pricefeed-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: pricefeed-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 3.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for pricefeed-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7ff23313fee6e7f8c61386b66710f20d57391dafe1bc0829abb0d71fd8b9a58f
MD5 c84479a8fe8bee7c7ed7375d473ec17f
BLAKE2b-256 21b3bdff63329a0199f932f2216c1c8d3e16d7cf8b786fe600513f5031c3cc64

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page