Skip to main content

A package for predicting buy and sell signals

Project description

Machine Learning Evx

This is a simplified version of regpredict package used to generate buy and sell signals for crypto and conventional stock markets based on the excess volume indicator(EVX). EVX is a concept where the bid-ask spread is estimated inherently from current market prices.

You can read more about Evx in the whitepaper here

Installation

Install mlevx with python3 -m pip install mlevx

Usage

In your python script simply import the module and use as follows:

from mlevx.regbot import signal
print(signal(20,65))

The above methods take an assets opening and closing prices of the asset based on the time interval you have chosen. A zero classification output would instruct the user to sell, while one output means don't sell or buy if the asset is not already present in the orders.

Testing an entire dataframe

Testing of a dataframe for correct buy, sell signals is as simple as applying the function as follows:

import pandas as pd
from mlevx.regbot import signal

df = pd.read_csv('../../../path/to_your.csv')

y_pred = []
def getSignal(open,close):
    return signal(open,close)


df = df[df['buy'] == 1]
print(df.head())

df['signal'] = df.apply(lambda row: getSignal(row['open'], row['close']), axis=1)

print(df.head())

print(len(df[df['signal'] == df['buy']]), len(df))

Your original data must already have some presumed 'buy' signal.

Warning

This is not financial advise. MlEVX is entirely on its preliminary stages. Use it at your own risk.

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

mlevx-0.0.1.tar.gz (7.8 MB view details)

Uploaded Source

Built Distribution

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

mlevx-0.0.1-py3-none-any.whl (7.9 MB view details)

Uploaded Python 3

File details

Details for the file mlevx-0.0.1.tar.gz.

File metadata

  • Download URL: mlevx-0.0.1.tar.gz
  • Upload date:
  • Size: 7.8 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.10.4

File hashes

Hashes for mlevx-0.0.1.tar.gz
Algorithm Hash digest
SHA256 1ad86ad88486ce03afc38283cddaa1046aa09cf5d88d4be728f41f47ff389133
MD5 1ad48c3385c1f03f7e45ae377813ae21
BLAKE2b-256 13030d489896148783630b6677c7a1d3ea197735c567752b75f600489aa6493f

See more details on using hashes here.

File details

Details for the file mlevx-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: mlevx-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 7.9 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.10.4

File hashes

Hashes for mlevx-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 14fb2d3e347a118caac4912b8d439fb36e5dd7745aca59902d4dd0d9a7ded634
MD5 95dafa8be240ca2d289dc4164d8eebf1
BLAKE2b-256 7a0cf1769d9bd1ad9bce594c17c1da7d3b152fe19fb18e25d10e06f6b3c17755

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