Saravanan666/pypi-org huggingface dataset:
Package: ye-tui
YET -Youtube export TUIyet is a console (kind of rss) application to download youtube videos. It usessubscriptions.jsonfile which comes with your youtube export data. It provides a minimalistic and nice curses interface. It usesyoutube-dlto download videos.DependenciesPython>=3.6youtube-dlxmltodictInstallationUsing PipYou can install yet through PyPi:pip install ye-tuiFrom sourceCheckout this project: git clonehttps://github.com/nevarman/yetcd /yetsudo python setup.py installUsageFirst export your youtube data fromhttps://takeout.google.com/, it should come with a subscriptions.json file. Move the subscriptions.json into ~/.config/yet folder.Run 'yet' from your terminal emulator.Use arrow keys or 'h,j,k,l' to navigate around.Dto download,Vto open in VLC media player(if installed) andOto open in browser. You can change the keybindings from the config file.The downloaded video files are saved under $HOME/Videos directory. You can change the path from config file.ConfigurationCopy the yet/config/yet.conf from this repo or from python package directory, into ~/.config/yet folder. The config file is self explanatory.
Package: yews
Yews is a deep learning toolbox for processing seismic waveform made with
flexibility, speed, and usability in mind. It is built uponPyTorchfor researchers interested in
applying deep learning techniques on seismic waveform data.InstallationTo ensure the GPU-poweredPyTorch,
first isntall PyTorch using the offical guide:https://pytorch.org/get-started/locally/and then installYewsvia one of the following approaches:conda:condainstall-clijunzhu-cpytorchyewsconda-forge:condainstall-cconda-forgeyewspip:pipinstallyewsFrom source:pythonsetup.pyinstallNote:Running the above command without first installing PyTorch may still work.
Depending on the OS, you may get either the GPU or CPU version of PyTorch.
For example, MacOS currently will get the CPU Pytorch while Linux will get
the GPU PyTorch by default. Please refer tohttps://pytorch.org/get-started/locally/for details.yewsby itself isnoarch, which means it is pure Python and OS
independent. Most inconsistenciews between OS’s are primarily due to the
upstream difference (e.g. PyTorch and NumPy).obspyis an optional dependency, which is used for seismic waveform I/O;
however,yews’s core functionalities do not depend onobspy.You can install allyewsoptional dependencies viapip install yews[all].Below are the instructions to each optional dependencies to install them
separately inconda.DependencyInstructionsobspyconda install-cconda-forgeobspyscipyconda install scipytqdmconda install tqdmDocumentationYou can find the API documentation on the yews website:https://www.yews.info/docs/ContributingWe appreciate all contributions. If you are planning to contribute back
bug-fixes, please do so without any further discussion. If you plan to
contribute new features, utility functions or extensions, please first open an
issue and discuss the feature with us.
Package: yex
yexWhat is it?It's a TeX workalike in pure Python.Why?Because.(There will be a more serious readme here later.)DemoAs of 2022-03-19, this:\def\TeX{T\kern-.1667em\lower.5ex\hbox{E}\kern-.125emX}
\shipout\hbox{This was set in Python by yex, not by \TeX.}gives this:LinksSVG source for the above)Gitlab repository.Please report lots of bugs.Github mirror, not always up to date.Licenced under the GPL version 2.
Package: yext
Yext API Client for PythonThis library contains utilities for interacting with the Yext API in Python.💡 Getting StartedFirst, install Yext Python API Client via thepippackage manager:pipinstall--upgrade'yext'Then, create entities in your Knowledge Graph:fromyextimportYextClientclient=YextClient('<your_api_key>')profile={'meta':{'id':'entity_id','countryCode':'US'},'name':'What is Yext Answers?','answer':'A revolutionary search product.'}entity_type='faq'client.create_entity(entity_type,profile)
Package: yfantasy-api
Yahoo Fantasy APIA simply Python client that can be used to make calls to the Yahoo! Fantasy Sports API.This library provides a fluent API to build and make calls to the Yahoo! Fantasy Sports API. It was developed specifically for NHL use initially, but should be generic enough to support MLB, NBA, and NFL as well.Installationpipinstallyfantasy_apiUsage examplesObtain team information, including the roster with player stats for March 31st 2021# The request url created is: /team/nhl.l.12345.t.1/roster/players/stats;type=date;date=2021-03-31fromyfantasy_api.apiimportYahooFantasyApileague_id=12345# This should be the id of the league you are queryinggame_id='nhl'# This should be the id of the game you are queryingteam_id=1# This should be the id of the team you are queryingapi=YahooFantasyApi(league_id,game_id)team=api\.team(team_id)\.roster()\.stats(date='2021-03-31')\.get()forplayerinteam.players:print(player.full_name,player.points)# Output:# Brock Nelson 0.00# Joel Eriksson Ek 0.05# Nazem Kadri 4.00# Alex Ovechkin 0.00# Jake Guentzel 0.00# ...truncated for brevity...Obtain draft_results, including player information for each pick.# The request url created is: /league/nhl.l.12345/draft_results/playersfromyfantasy_api.apiimportYahooFantasyApileague_id=12345# This should be the id of the league you are queryinggame_id='nhl'# This should be the id of the game you are queryingteam_id=1# This should be the id of the team you are queryingapi=YahooFantasyApi(league_id,game_id)league=api\.league()\.draft_results()\.players()\.get()fordraft_resultinleague.draft_results:print(f'{draft_result.round}-{draft_result.pick}-{draft_result.player.full_name}')# Output:# 1 - 1 - Connor McDavid# 1 - 2 - Alex Ovechkin# 1 - 3 - Patrick Kane# 1 - 4 - Steven Stamkos# 1 - 5 - Sidney Crosby# ...truncated for brevity...For working examples of the above scenarios, seeexamples.pyDevelopment setupI suggest you use some form of virtual environment to avoid clashing dependencies, but that is obviously your call. My suggested virtual environment isvirtualenvwrapper.gitclonegit@github.com:hkyplyr/yfantasy-api.git
...cdyfantasy_api
...
pipinstall-rrequirements.txtRelease HistoryTODOMetaTravis Paquette -@hkyplyr-tpaqu15@gmail.comDistributed under the MIT license. SeeLICENSEfor more information.How to ContributeClone repo and create a new branch: $ git checkout -b short_feature_name.Make changes and testSubmit a Pull Request
Package: yfbasic
yfbasicA thin python wrapper to retrieve price action data from the Yahoo! finance API.There are similar packages available that does this, most notablyyfinance. The purpose of this package
is to present the raw data as typed objects to be consumed as desired.Getting startedThe interface is straight forward, just import and query.importyfbasicdata=yfbasic.query("GME")The supporting parameters are typed as well.importyfbasicfromyfbasicimportRange,Intervaldata=yfbasic.query("GME",range=Range.r1mo,interval=Interval.i1h)You can usequery_threadedto parallelise the data retrieval.importyfbasicsymbols=("GME","AMC","TSLA")data=yfbasic.query_threaded(symbols)Working with the dataThe data is modelled directly of the structure returned by the yahoo api. This
makes it a bit more low level to work with, but the package makes no presumptions about
how you intend to work with the data.The best way to understand the data is to look at thedata structuredirectly.Error handlingIf we look at theChartdata model it contains two optional parameters,resultanderrorwhich means we need to do application side checking of the
data. To satisfy type safety we need to at least verify the existence of
results by checkingdata.chart.results. If we want insight into any API side
errors we could verify and action upondata.chart.errorimportyfbasicdata=yfbasic.query("GME")# verifying the API produced results.ifdata.chart.result:result=data.chart.result[0]quotes=result.indicators.quote[0]# getting price action datatimestamps=result.timestampopen=quotes.openclose=quotes.closehigh=quotes.highlow=quotes.lowvolume=quotes.volume
Package: yfinance2pg
yfinance2pgDownload financial data to postgres database from yahoo finance.usage:
    yfinance2pg [options]

options:
    --help
        help menu
    --exclude [value,...]
        skip download phase, possible list
        values are `companies` or `priceVolume`
    --host [string]
    --user [string]
    --dbname [string]
    --port [string]
    --password [string]
        postgres connection options
Package: yfinanceapi
yfinanceapi (Equity and currency information API)Description-----------The yfinanceapi is an API for Python that builds on top of the Yahoo! finance JSON API to provide equity and currency information, such as price, volume, last trade time etc.Installation------------The API can be installed from PyPi using the following command:pip install yfinanceapiInstructions on installing pip can be found here: https://pip.pypa.io/en/latest/installing.htmlAlternatively, it can be installed using github:pip install git+https://github.com/Karthik005/yfinanceapi#egg=yfinanceapiThe installation may require root permissions.Usage-----The API can be imported in the following manner:import yfinanceapi as apiStock/equity information is obtained as follows:api.get_prices(['GOOG','MSFT','INFY.NS'])api.get_volumes(['GOOG','MSFT','INFY.NS'])Prices are in currency values of the country in which symbol is listedCurrency information is obtained as follows:api.get_currency_prices(['INR','JPY'])api.get_currency_utc(['INR','JPY'])Currency values are measured with respect to USD.Additional functions, information on usage and allowed symbol values can be found in the docstrings of the api.py file.Copyright---------Copyright 2015, Karthik.SLicense-------This project is licensed under GNU v2.0. For more information read the LICENSE.txt file.Bugs and requests----------------Bugs and feature requests can be reported at karthikbharadwaj005@gmail.com
Package: yfinance-extended
yfinance Package with Wide-Form Data Support and Data Exportyfinance-extendedextendsyfinancepackage by Ran Aroussi and make it easier to:Retrieve multiple-ticker intraday price data in a wide-formpandasdataframe;Read options data for all available expiration dates;Retrieve top-of-the-book bid-ask prices and sizes; and,Store data in the parquet format with the following structure:./saved_data
├── AAPL
│   ├── AAPL-2023-04-24.parquet
│   ├── AAPL-2023-04-25.parquet
│   ├── AAPL-2023-04-26.parquet
│   ├── AAPL-2023-04-27.parquet
│   └── AAPL-2023-04-28.parquet
└── TSM
    └── TSM-2023-04-24.parquet
    └── TSM-2023-04-25.parquet
    └── TSM-2023-04-26.parquet
    └── TSM-2023-04-27.parquet
    └── TSM-2023-04-28.parquetSample UsageGet Historical DataGetting past five days of minute-by-minute prices of Apple, Inc., including pre-/post-market data.importyfinance-extendedasyfeloader=yfe.YahooBatchLoader()price_df=get_historical_prices("AAPL",period="5d",interval="1m",prepost=True)prices_df=get_historical_prices(["AAPL","GOOGL"],period="5d",interval="1m",prepost=True)Read all Available Options Informationoptions_df=loader.options_data("AAPL")Get Top-of-the-Book Datalive_prices_df=loader.get_prices("AAPL")live_prices_df=loader.get_prices(["AAPL","GOOGL"])Save to and Read Data from Parquet FilesSave files:prices_df=get_historical_prices(["AAPL","GOOGL"],period="5d",interval="1m",prepost=True)yfe.to_parquet(prices_df,root_dir="./data")Read files:prices_df=yfe.read_parquet(root_dir="./data")Alternatively, if you wish to save all data into one file:# Write to one fileyfe.to_parquet(prices_df,filepath="./data/datafile.parquet")# Read from the fileprices_df=yfe.read_parquet(filepath="./data/datafile.parquet")
Package: yfinance-ez
Yahoo! Finance market data downloader=====================================Ever sinceYahoo! finance <https://finance.yahoo.com>_ decommissioned
their historical data API, many programs that relied on it to stop working.yfinance_ezaimes to solve this problem by offering a reliable
and Pythonic way to download historical market data from Yahoo! finance.Note from Ezra:This library was originally created by Ran Aroussi and namedyfinance. I encountered
some bugs using it and wasn't able to reach him about updating his package, so I've
renamed it for now to yfinance-ez so I can work on it. I've done some significant restructuring
and added improved documentation, but the credit for much of the html parsing code is not mine.
I've also pared down the package to focus just on the Ticker
class and its functionality which I've gotten working.Quick StartThe Ticker moduleTheTickermodule, which allows you to access
ticker data in amore Pythonic way:importyfinance_ezasyfmsft=yf.Ticker("MSFT")# get stock infomsft.info# get historical market data for the last quarter# This method also accepts start and end dates and/or time intervals# so you can customize what you're looking for.hist=msft.get_history(period=yf.TimePeriods.Quarter)# show actions (dividends, splits) for the last retrieved historical periodmsft.actions# show dividends for the last retrieved historical periodmsft.dividends# show splits for the last retrieved historical periodmsft.splits# show financialsmsft.financialsmsft.quarterly_financials# show major holdersmsft.major_holders# show institutional holdersmsft.institutional_holders# show balance heetmsft.balance_sheetmsft.quarterly_balance_sheet# show cashflowmsft.cashflowmsft.quarterly_cashflow# show earningsmsft.earningsmsft.quarterly_earnings# show sustainabilitymsft.sustainability# show analysts recommendationsmsft.recommendations# show next event (earnings, etc)msft.calendar# get option chain for specific expirationopt=msft.option_chain('YYYY-MM-DD')# data available via: opt.calls, opt.putsIf you want to use a proxy server for downloading data, use:importyfinance_ezasyfmsft=yf.Ticker("MSFT",proxy="PROXY_SERVER")If you want to get history data for multiple tickers using async, use:importyfinance_ezasyfasyncdefget_history_multiple_tickers(ticker_symbols:List[str],**kwargs)->List[yf.Ticker]:tickers=[yf.Ticker(ticker_symbol)forticker_symbolinticker_symbols]awaitasyncio.gather(*[ticker.get_history_async(**kwargs)fortickerintickers])returntickersInstallationInstallyfinance_ezusingpip:$pipinstallyfinance_ezRequirementsPython <https://www.python.org>_ >= 3.5+Pandas <https://github.com/pydata/pandas>_ (tested to work with >=0.23.1)Numpy <http://www.numpy.org>_ >= 1.11.1requests <http://docs.python-requests.org/en/master/>_ >= 2.14.2Legal Stuffyfinance_ezis distributed under theApache Software License. See theLICENSE.txt <./LICENSE.txt>_ file in the release for details.P.S.Please drop me an note with any feedback you have.Ezra Schiff
Package: yfinance-timeframe-converter
yfinance-timeframe-converterConverts an YFinance DataFrame to other timeframeInstead of calling the yFinance's API again, why not just to convert your current DataFrame, making the whole process faster? Or to convert it to a non-downloadable timeframe?This is whatyfinance-timeframe-converterdoes.Convert your DataFrame to up to33 timeframesof your choise,22 more than the yFinancetimeframes available.Uses C++ functions to make all process faster, converting large amount of data in less than 0.1 seconds.How to useHow to convert a DataFrameThetimeframe_converterfunction allows you to convert your DataFrame.To convert a DataFrame, pass the original DataFrame, the DataFrame's timeframe, and the output desired timeframe.importyfinance_timeframe_converterasconverterfrompandas_datareaderimportdataaspdrimportyfinanceasyfticket="AAPL"input_timeframe="1d"output_timeframe="1wk"yf.pdr_override()df=pdr.get_data_yahoo(tickers=ticket,interval=input_timeframe)# Pass the dataframe, the timeframe of the Dataframe, and the timeframe desired. Returns the converted DataFrameconverted_timeframe=converter.timeframe_converter(df,input_timeframe,output_timeframe)Argumentsdata- pd.DataFrame -> The dataframe you desire to converttimeframe_input- string -> The timeframe of the DataFrametimeframe_output- string -> The timeframe you desire to convert tochecking- bool -> Checks if all variables are valid, if False, the code will run about 10% faster, you can have serious errorsHow many timeframes are available to use?importyfinance_timeframe_converterasconverter# Gets all timeframes available to donwload from yFinance - 13 timeframesprint(converter.yfinance_available_timeframes)# ["1m", "2m", "5m", "15m", "30m", "60m", "90m", "1h", "1d", "5d", "1wk", "1mo", "3mo"]# Gets all timeframes available to pass as input to the function - 35 timeframesprint(converter.converter_available_inputs)# ["1m", "2m", "3m", "4m", "5m", "6m", "10m", "12m", "15m", "20m", "30m", "60m", "1h", "90m", "2h", "3h", "4h", "6h", ... "4mo", "6mo", "1yr", "2yr"]# Gets all Outputs available of the function - 33 timeframesprint(converter.converter_available_outputs)# ["1m", "2m", "3m", "4m", "5m", "6m", "10m", "12m", "15m", "20m", "30m", "60m", "1h", "90m", "2h", "3h", "4h", "6h", ... "4mo", "6mo", "1yr", "2yr"]# Gets all convertions availableprint(converter.available_convertions)# {"1m" = ["2m", "3m", "4m", "5m", "6m", "10m", "12m", "15m", "20m", "30m", "60m", "1h"...]}
Package: yfind
Search YAML files satisfying specified conditions.Depends on Python 3.Examples:yfind'.mailings[0].sent< 2012/06/12' my_files/yfind '.id == 10'((?.id)and (yfind '.id == 10)) or (.enabled =="False")'Currently supported search expressions:<Operand> <Operator> <Operand>where Operator is one of ==, !=, <, >, <= or >=.Operands may be numbers (1, 3.0), scalars (“foo”, “bar”), dates
(2007/12/30) or YAML fields (.foo.bar, .foo[4].bar, .bar).To check for existance of a field, use ‘?’ before the field name:?.foo.bar.Search expression can be combined with the logical operators “and, or,
not”:not (<SearchExpression>)(<SearchExpression>) and (<SearchExpression>)(<SearchExpression>) or (<SearchExpression>)History0.1.0a2 - 2012/08/21Added boolean operations (and, or, not)
Package: yfinhanced
A simple asyncronous wrapper around the public yahoo finance APIWhile the yahoo finance website is clunky and basic - underlying it is a very
powerful API that is primarily powered by refinitiv data. Many python packages
have attempted to implement wrappers around this API, however they fall short
for one of two reasons. Either they don’t expose all of the available endpoints
of the API, or they are syncronous / rely on threading which is less efficient
for IO bound tasks.yfinhancedattempts to solve both of these issues by providing access to the
full range of endpoints, and using pythons modern asyncronous support inasyncioandaiohttp. As a result, this package is extremely fast and
feature complete.You can find the full documentation at:https://me-64.github.io/yfinhanced>>>fromyfinhancedimportYFClient>>>yf=YFClient()>>>awaityf.connect()>>>quote=awaityf.get_quote(['AAPL','BTC-USD','BYND220401C00030000','GC=F','AZN.L'])>>>print(quote['AAPL']){'language':'en-US','region':'US','quoteType':'EQUITY','typeDisp':'Equity','quoteSourceName':'Nasdaq Real Time Price','triggerable':True,'customPriceAlertConfidence':'HIGH','currency':'USD','exchange':'NMS','shortName':'Apple Inc.','longName':'Apple Inc.','messageBoardId':'finmb_24937','exchangeTimezoneName':'America/New_York','exchangeTimezoneShortName':'EDT','gmtOffSetMilliseconds':-14400000,'market':'us_market','esgPopulated':False,'fullExchangeName':'NasdaqGS','financialCurrency':'USD','regularMarketOpen':167.99,'averageDailyVolume3Month':93351350,'averageDailyVolume10Day':97387620,'fiftyTwoWeekLowChange':51.429993,'fiftyTwoWeekLowChangePercent':0.43269387,'fiftyTwoWeekRange':'118.86 - 182.94','fiftyTwoWeekHighChange':-12.650009,'fiftyTwoWeekHighChangePercent':-0.06914841,'fiftyTwoWeekLow':118.86,'fiftyTwoWeekHigh':182.94,'dividendDate':1644451200,'earningsTimestamp':1643301000,'earningsTimestampStart':1651003200,'earningsTimestampEnd':1651521600,'trailingAnnualDividendRate':0.865,'trailingPE':28.310888,'trailingAnnualDividendYield':0.0051238,'epsTrailingTwelveMonths':6.015,'epsForward':6.56,'epsCurrentYear':6.16,'priceEpsCurrentYear':27.64448,'sharesOutstanding':16319399936,'bookValue':4.402,'fiftyDayAverage':166.388,'fiftyDayAverageChange':3.9019928,'fiftyDayAverageChangePercent':0.023451166,'twoHundredDayAverage':154.8563,'twoHundredDayAverageChange':15.433701,'twoHundredDayAverageChangePercent':0.099664666,'marketCap':2779030487040,'forwardPE':25.958841,'priceToBook':38.68469,'sourceInterval':15,'exchangeDataDelayedBy':0,'firstTradeDateMilliseconds':345479400000,'priceHint':2,'regularMarketChange':1.469986,'regularMarketChangePercent':0.87074155,'regularMarketTime':1648046328,'regularMarketPrice':170.29,'regularMarketDayHigh':170.76,'regularMarketDayRange':'167.65 - 170.76','regularMarketDayLow':167.65,'regularMarketVolume':24929352,'regularMarketPreviousClose':168.82,'bid':170.08,'ask':170.13,'bidSize':12,'askSize':8,'marketState':'REGULAR','pageViewGrowthWeekly':-0.10239728,'averageAnalystRating':'1.8 - Buy','tradeable':False,'displayName':'Apple'}
Package: yflive
yflive v1.0.0yflive is aYahoo! Financelive data streamer. Originally created as an alternative to scraping prices of Yahoo! Finance, yflive implements a websocket client for receiving live quotes from Yahoo! Finance directly.For historic prices or other financial information,yfinanceis recommended.InstallationUse the package managerpipto install yflive.pipinstallyfliveUsageQuick startThe following example shows a simple setup, which subscribes to the tickers AAPL and TSLA and prints received quotes until interrupted.fromyfliveimportQuoteStreamerqs=QuoteStreamer()qs.subscribe(["AAPL","TSLA"])qs.on_quote=lambdaqs,q:print(q)# Non-blocking if should_thread=True (default is False)qs.start(should_thread=False)Quotes are in real time (withexceptions) and normally only available during trading hours.For additional information regarding Yahoo! Finance data, please refer to their section on data accuracy foundhere.CollaborationThis is very early stagePull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.Please make sure to update tests as appropriate.Licenseyfliveis distributed under theApache-2.0 License. ReviewLICENSE.txtfor further information.
Package: yfml
some simple functions based on tensorflow#####################Simple Example here#####################import tensorflow as tffrom yfml.layers import *from yfml.train import *from yfml.utils import *from yfml.quick_build import *from tensorflow.examples.tutorials.mnist import input_datamnist = input_data.read_data_sets('MNIST_data', one_hot=True)train_data, train_label = mnist.train.next_batch(50000)training_data = Data(train_data, train_label)x = fl_holder([None, 784])y = fl_holder([None, 10])if_training = bool_holder()x_ = reshape(x, [-1, 28, 28, 1])final = mix_stack('stack', x_, types=['conv2d', 'maxpool2d', 'conv2d', 'maxpool2d', 'fc', 'fc'],shapes=[16, 2, 32, 2, 256, 10], use_batch_norm=False, if_training=if_training,activation_fn='relu', last_activation_fn='softmax')loss = loss_fn(final, y)opt = optimize(loss, 0.001, optimizer='adam', regularizer=['l2', 0.001])accuracy = compute_accuracy(final, y)sess = tf.Session()sess.run(tf.global_variables_initializer())for i in range(1000):training_data.shuffle()iter = 50000//100avg_acc = 0.for j in range(iter):xs, ys = training_data.next_batch(100)acc, _ = sess.run([accuracy, opt], {x: xs, y: ys, if_training:True})avg_acc += acc/iterprint('accuracy is : ', avg_acc)
Package: yfoption
InformationThis package to only fetch option data from yahoo financeInstallationpipinstallyfoptionGet options as straddleGet options of ticker as straddleimportyfoptionasyfopt=yf.Option("AAPL")opt.option_straddle('2021-12-23')Get optionsGet options of tickerimportyfoptionasyfopt=yf.Option("AAPL")opt.optionsGet strikesGet strikes of tickerimportyfoptionasyfopt=yf.Option("AAPL")opt.strikes