Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/yageek/tulipindicators-swift
:bar_chart: Swift Technical Analysis library around tulip
https://github.com/yageek/tulipindicators-swift
swift technical-analysis tulip
Last synced: 3 months ago
JSON representation
:bar_chart: Swift Technical Analysis library around tulip
- Host: GitHub
- URL: https://github.com/yageek/tulipindicators-swift
- Owner: yageek
- License: lgpl-3.0
- Created: 2019-06-04T15:28:50.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-08-27T09:32:09.000Z (over 4 years ago)
- Last Synced: 2024-09-15T02:42:37.652Z (4 months ago)
- Topics: swift, technical-analysis, tulip
- Language: C
- Homepage: https://yageek.github.io/tulipindicators-swift/
- Size: 424 KB
- Stars: 22
- Watchers: 3
- Forks: 4
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- Changelog: Changelog.md
- License: LICENSE
Awesome Lists containing this project
README
# tulipindicators-swift
[![License](https://img.shields.io/github/license/yageek/tulipindicators-swift.svg)](LICENSE)
[![Carthage compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage)
[![Cocoapods](https://img.shields.io/cocoapods/v/tulipindicators-swift.svg)](https://img.shields.io/cocoapods/v/tulipindicators-swift.svg)This swift package offers a technical analysis function by wrapping the [tulipindicators C library](https://tulipindicators.org)
## Installation
You can access the documentation [here](https://yageek.github.io/tulipindicators-swift/)
### Swift package manager
```swift
import PackageDescriptionlet package = Package(
dependencies: [
.package(url: "https://github.com/yageek/tulipindicators-swift.git", from: "1.0.1"),
]
)
```### Carthage
```
github "yageek/tulipindicators-swift" ~> 1.0.1
```### Cocoapods
```
pod 'tulipindicators-swift' ~> 1.0.1
```## Usage
```swift
import tulipindicatorslet inputs: [Double] = [81.59, 81.06, 82.87, 83.00, 83.61, 83.15, 82.84, 83.99, 84.55, 84.36, 85.53, 86.54, 86.89, 87.77, 87.29]
let (beginIdx, outputs) = msw(inputs, period: 5)print("Relative Input offset: \(beginIdx)")
print("MSW values: \(outputs)")
```