semvec/pypi-packages huggingface dataset:
krakenforwarder 0.8
Forwards trades from Kraken.com to TCP port
License: MIT

# krakenforwarder
This Python program listens to trades from Crypto-exchange platform Kraken (https://www.kraken.com) and forwards them on a TCP port so you can plug in anything, like a live algorithmic trader or a live analysis tool.

## Installation

```pip3 install krakenforwarder``` 

## Usage

Launch the forwarder in sub-process, then listen

```python
import time
from multiprocessing import Process

from krakenforwarder.forwarder import KrakenForwarder
from krakenforwarder.listener import listen
from krakenforwarder.util import *

cfg_forwarders = [
    {
        F_PULL_PERIOD: 5,  # in seconds
        F_ASSET_PAIR: 'XXBTZEUR',  # see https://support.kraken.com/hc/en-us/articles/360000920306-Ticker-pairs
        F_TYPE: V_SPOT,
        F_ZMQ_PUBLISH_PORT: 5555
    },
    {
        F_PULL_PERIOD: 5,  # in seconds
        F_ASSET_PAIR: 'XETHZEUR',  # see https://support.kraken.com/hc/en-us/articles/360000920306-Ticker-pairs
        F_TYPE: V_SPOT,
        F_ZMQ_PUBLISH_PORT: 5556
    },
]

cfg_listener = {
    F_KEY_ZMQ_HOSTNAME: 'localhost',
    F_ZMQ_PUBLISH_PORT: [cfg[F_ZMQ_PUBLISH_PORT] for cfg in cfg_forwarders]
}

proc_forwarders = []
for cfg in cfg_forwarders:
    kraken_forwarder = KrakenForwarder(cfg)
    forward_process = Process(target=kraken_forwarder.forward)
    proc_forwarders.append(forward_process)

for proc in proc_forwarders:
    proc.start()

time.sleep(1)

for msg in listen(cfg_listener):
    print(msg)

for proc in proc_forwarders:
    proc.join()
```

This prints trades in console:

```
{"pair": "XXBTZEUR", "Trade": ["9388.90000", "0.01604115", 1568346002.9574, "b", "m", ""]}
{"pair": "XXBTZEUR", "Trade": ["9390.00000", "0.03569491", 1568346002.9981, "b", "m", ""]}
{"pair": "XXBTZEUR", "Trade": ["9390.00000", "0.01000000", 1568346003.0047, "b", "m", ""]}
{"pair": "XXBTZEUR", "Trade": ["9392.90000", "0.03477392", 1568346003.0213, "b", "m", ""]}
OVER
...
{"pair": "XXBTZEUR", "Trade": ["9384.50000", "0.00500000", 1568346015.5326, "s", "m", ""]}
OVER
{"pair": "XETHZEUR", "Trade": ["162.98000", "0.24458271", 1568346014.6035, "s", "m", ""]}
{"pair": "XETHZEUR", "Trade": ["162.98000", "0.00063427", 1568346014.6274, "s", "m", ""]}
{"pair": "XETHZEUR", "Trade": ["162.98000", "0.00000165", 1568346014.6296, "s", "m", ""]}
OVER

```

To call forward contracts, instead use

```python
from krakenforwarder.util import *
cfg_forwarders = [
    {
        F_PULL_PERIOD: 5,  # in seconds
        F_ASSET_PAIR: 'pi_xbtusd',
        F_TYPE: V_FUTURES,
        # see https://support.kraken.com/hc/en-us/articles/360022839531-Tickers for possible choices
        F_ZMQ_PUBLISH_PORT: 5557
    },
]
```
stochastics 0.4.0
Python solution for Stochastics
License: MIT
Requires Python: >=3.8

# Welcome to stochastics
![Version](https://img.shields.io/badge/version-0.4.0-blue.svg?cacheSeconds=2592000)
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/stochastics)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)

> A simple library to help solving stochastic processes and finding resulting probilities of common applications

## Installation / How to use

To use this library is pretty easy. First you will need to install the library from PyPI. Make sure you are running Python version 3.8 or above:
```sh
pip install stochastics
```

The you can use the library in your own python code, like this:
```python
from stochastics.models import MarkovChain

# define some initial values for a markov chain
initial_probabilities = [0.3, 0.4]
transition_matrix = [
    [0.1, 0.9],
    [0.7, 0.3],
]

# create the markov chain with the parameters
mc = MarkovChain(initial_probabilities, trans_matrix=transition_matrix)
# find the probability of ending up in a state given a sequence of steps
p = mc.get_probability_from_sequence(state_sequence=[0, 1, 0])
print(p)
```

More utilization examples and API documentation can be seem in the **docs**.

## Development Setup

So you want to contribute to the development, that is very welcome! To develop this project there're only two initial requirements:

- Python 3.8+
- Having pip or pipenv installed

After making sure those requirements are fullfilled, you can simple run this command with `pip`:
```sh
pip install -r requirements-dev.txt
```

If you like `pipenv`, just do:
```sh
pipenv install --dev
```

That is already all you need. Just make sure to follow the Contribution Guidelines and you are all set.

After doing your work and getting ready to make your PR, I recommend you to use `pre-commit` to fix some standards and make sure nothing really can get in the way of your contribution.

## Run tests

There're tests in this project, and the best way to see how things work under the hood and check if you changes are ok, simply run the tests with `pytest`:
```sh
pytest
```

You can also see if the current test coverage of the project is good by running:
```sh
pytest --cov
```

## Need help? Found an bug? Have a good idea?

I encourage you to look around in the [issues](https://github.com/deadpyxel/stochastics/issues) section, see if someone else is working on a fix for your problem, there's already a report for the bug, or some new feature being dicussed that you are interested. If you found nothing, feel free to create an issue using one of the provided templates.

## Author

**Robson Cruz**

* Website: https://deadpyxel.github.io/
* Github: [@deadpyxel](https://github.com/deadpyxel)

## Show your support

Give a ⭐️ if this project helped you!


***
_This README was generated with ❤️ by [readme-md-generator](https://github.com/kefranabg/readme-md-generator)_
marco-test-package 0.1.0
Test package for marco
License: MIT
Requires Python: >=3.7,<4.0

# Marco test package


[![PyPI version](https://badge.fury.io/py/marco_test_package.svg)](https://badge.fury.io/py/marco_test_package)
![versions](https://img.shields.io/pypi/pyversions/marco_test_package.svg)
[![GitHub license](https://img.shields.io/github/license/mgancita/marco_test_package.svg)](https://github.com/mgancita/marco_test_package/blob/main/LICENSE)



[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)


Test package for marco


- Free software: MIT
- Documentation: https://mgancita.github.io/marco-test-package.


## Features

* TODO

## Credits


This package was created with [Cookiecutter](https://github.com/audreyr/cookiecutter) and the [`mgancita/cookiecutter-pypackage`](https://mgancita.github.io/cookiecutter-pypackage/) project template.
graphby 0.0.3
Generate simple visualizations on terminal.
License: MIT
Requires Python: >=3.6
Keywords: CLI,Graph,Visualization

# graphby
Generate simple visualizations on terminal.

## Import
**graphby** can now be used on your Python projects through PyPi by running pip command on a Python-ready environment.
`pip import --upgrade graphby`

## Usage
**1. Import package**
```python
from graphby import Bar
```

**2. Basic usage**
```python
from graphby import Bar

labels = ["a", "b", "c", "d"]
values = [1, 2, 3, 4]
Bar(labels, values).plot()
---

a: **         1
b: *****      2
c: ********   3
d: ********** 4
```

**3. Negative numbers**
```python
from graphby import Bar

labels = ["a", "b", "c", "d"]
values = [200, -350, 20, 999]
Bar(labels, values).plot()
---

a: ****        200
b:            -350
c: ***          20
d: **********  999
```

**4. Custom symbol**
```python
from graphby import Bar

labels = ["a", "b", "c", "d"]
values = [200, -350, 20, 999]
Bar(labels, values, bar="+").plot()
---

a: ++++        200
b:            -350
c: +++          20
d: ++++++++++  999
```


**5. Expand graph**
```python
from graphby import Bar

labels = ["a", "b", "c", "d"]
values = [200, -350, 20, 999]
Bar(labels, values, limit=15).plot()
---

a: ******           200
b:                 -350
c: ****              20
d: ***************  999
```


**6. Customizations**
```python
from graphby import Bar

labels = ["a", "b", "c", "d"]
values = [200, -350, 20, 999]
Bar(labels, values, bar="#", limit=5).plot()
---

a: ##     200
b:       -350
c: #       20
d: #####  999
```