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 (about 6 years ago)
- Default Branch: master
- Last Pushed: 2020-08-27T09:32:09.000Z (almost 5 years ago)
- Last Synced: 2025-03-25T15:01:40.824Z (3 months ago)
- Topics: swift, technical-analysis, tulip
- Language: C
- Homepage: https://yageek.github.io/tulipindicators-swift/
- Size: 424 KB
- Stars: 22
- Watchers: 2
- 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://github.com/Carthage/Carthage)
[](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)")
```