TTR
Technical analysis and other functions to construct technical trading rules with R
Science Score: 26.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
○DOI references
-
○Academic publication links
-
○Committers with academic emails
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (13.8%) to scientific vocabulary
Keywords
Repository
Technical analysis and other functions to construct technical trading rules with R
Basic Info
Statistics
- Stars: 342
- Watchers: 46
- Forks: 102
- Open Issues: 28
- Releases: 8
Topics
Metadata Files
README.md
About
TTR is an R package that provides the most popular technical analysis functions for financial market data. Many of these functions are used as components of systematic trading strategies and financial charts.
Supporting TTR development
If you are interested in supporting the ongoing development and maintenance of TTR, please consider becoming a sponsor.
Installation
The current release is available on CRAN, which you can install via:
r
install.packages("TTR")
To install the development version, you need to clone the repository and build from source, or run one of:
```r
lightweight
remotes::install_github("joshuaulrich/TTR")
or
devtools::install_github("joshuaulrich/TTR") ```
You will need tools to compile C/C++ code. See the relevant appendix in the R Installation and Administration manual for your operating system:
- Windows
- MacOS (the R for Mac OS X Developer's Page might also be helpful)
- Unix-alike
Getting Started
Here are a few examples of some of the more well-known indicators:
```r
"TTR Composite" (simulated data)
data(ttrc) hlc <- ttrc[, c("High", "Low", "Close")]
Bollinger Bands
bbands <- BBands(hlc)
Directional Movement Index
adx <- ADX(hlc)
Moving Averages
ema <- EMA(ttrc[, "Close"], n = 20) sma <- SMA(ttrc[, "Close"], n = 20)
MACD
macd <- MACD(ttrc[,"Close"])
RSI
rsi <- RSI(ttrc[,"Close"])
Stochastics
stochOsc <- stoch(hlc) ```
TTR works with the chartSeries() function in quantmod. Here's an example that uses chartSeries() and adds TTR-calculated indicators and overlays to the chart.
```r library(quantmod) data(ttrc)
create an xts object
x <- as.xts(ttrc)
chartSeries(x, subset = "2006-09/", theme = "white") addBBands() addRSI() ```
Have a question?
Ask your question on Stack Overflow or the R-SIG-Finance mailing list (you must subscribe to post).
Contributing
Please see the Contributing Guide.
See Also
Author
Owner
- Name: Joshua Ulrich
- Login: joshuaulrich
- Kind: user
- Location: Saint Louis, Missouri, USA
- Website: http://about.me/joshuaulrich
- Repositories: 70
- Profile: https://github.com/joshuaulrich
GitHub Events
Total
- Issues event: 4
- Watch event: 11
- Issue comment event: 3
- Push event: 2
- Fork event: 2
Last Year
- Issues event: 4
- Watch event: 11
- Issue comment event: 3
- Push event: 2
- Fork event: 2
Committers
Last synced: 8 months ago
Top Committers
| Name | Commits | |
|---|---|---|
| Joshua Ulrich | j****h@g****m | 340 |
| Brian G. Peterson | b****n@b****m | 5 |
| Jeffrey A. Ryan | j****n@g****m | 4 |
| Ethan Smith | 2****h | 2 |
| Blaine Bublitz | b****e@t****m | 2 |
| harvey131 | 2****1 | 1 |
| Serkan Korkmaz | 7****1 | 1 |
| Luis Damiano | d****s@g****m | 1 |
| James Toll | j****s@j****m | 1 |
| pcc | p****l@w****m | 1 |
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: 6 months ago
All Time
- Total issues: 101
- Total pull requests: 11
- Average time to close issues: 9 months
- Average time to close pull requests: 6 months
- Total issue authors: 62
- Total pull request authors: 8
- Average comments per issue: 2.39
- Average comments per pull request: 2.82
- Merged pull requests: 6
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 1
- Pull requests: 0
- Average time to close issues: 15 days
- Average time to close pull requests: N/A
- Issue authors: 1
- Pull request authors: 0
- Average comments per issue: 1.0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- joshuaulrich (21)
- ethanbsmith (10)
- amirmazmi (3)
- siims-biz (2)
- evelynmitchell (2)
- ghost (2)
- yogat3ch (2)
- AndreMikulec (2)
- Shicheng-Guo (2)
- Javdat (2)
- FrancisHChen (2)
- LiberTang0 (1)
- dcmg21 (1)
- SatoshiReport (1)
- vaclavcepelak (1)
Pull Request Authors
- ethanbsmith (3)
- phated (2)
- serkor1 (2)
- Chuluujav (1)
- jgehw (1)
- davft (1)
- harvey131 (1)
- nateaff (1)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 4
-
Total downloads:
- cran 222,799 last-month
- Total docker downloads: 33,625,347
-
Total dependent packages: 27
(may contain duplicates) -
Total dependent repositories: 150
(may contain duplicates) - Total versions: 40
- Total maintainers: 1
cran.r-project.org: TTR
Technical Trading Rules
- Homepage: https://github.com/joshuaulrich/TTR
- Documentation: http://cran.r-project.org/web/packages/TTR/TTR.pdf
- License: GPL-2 | GPL-3 [expanded from: GPL (≥ 2)]
-
Latest release: 0.24.4
published about 2 years ago
Rankings
Maintainers (1)
proxy.golang.org: github.com/joshuaulrich/ttr
- Documentation: https://pkg.go.dev/github.com/joshuaulrich/ttr#section-documentation
- License: gpl-2.0
-
Latest release: v0.24.4
published about 2 years ago
Rankings
proxy.golang.org: github.com/joshuaulrich/TTR
- Documentation: https://pkg.go.dev/github.com/joshuaulrich/TTR#section-documentation
- License: gpl-2.0
-
Latest release: v0.24.4
published about 2 years ago
Rankings
conda-forge.org: r-ttr
- Homepage: https://github.com/joshuaulrich/TTR
- License: GPL-2.0-or-later
-
Latest release: 0.24.3
published almost 4 years ago
Rankings
Dependencies
- quantmod * enhances
- curl * imports
- xts >= 0.10 imports
- zoo * imports
- RUnit * suggests