@quantgate-systems/sentiment
v0.2.16
Published
`npm i --save @quantgate-systems/sentiment` or if you are using yarn, ` yarn add @quantgate-systems/sentiment`
Downloads
4
Readme
SentimentGraph
Installation
npm i --save @quantgate-systems/sentiment
or if you are using yarn,
yarn add @quantgate-systems/sentiment
Usage
In order to use Sentiment Graph, create a user on Pilot application and pass your credentials to Sentiment component
Note
When using create-react-app please ensure you are using the latest version of react
and react-dom
, i.e. ^18.1.0
create-react-app
import {SentimentSpectrumApp} from '@quantgate-systems/sentiment';
const [currentSymbol, setCurrentSymbol] = useState('MSFT');
//sample handler for click change symbol
const handleSymbolChange = useCallback(() => {
setCurrentSymbol('AAPL');
}, []);
return (
<SentimentSpectrumApp
credentials={{
UserName: 'your user name',
Password: 'your password',
}}
brokerName={
'simulation-mode' ||
'demo-mode' ||
'signals-only' ||
'paper-forex' ||
'alt5' ||
'bitfinex' ||
'binance' ||
'bittrex' ||
'bitstamp' ||
'gemini' ||
'kraken' ||
'liquid'
}
symbol={currentSymbol}
width={500}
/>
);
next.js
import dynamic from 'next/dynamic';
const SentimentSpectrumApp = dynamic(() => import('@quantgate-systems/sentiment'));
const [currentSymbol, setCurrentSymbol] = useState('MSFT');
//sample handler for click change symbol
const handleSymbolChange = useCallback(() => {
setCurrentSymbol('AAPL');
}, []);
return (
<SentimentSpectrumApp
credentials={{
UserName: 'your user name',
Password: 'your password',
}}
brokerName={
'simulation-mode' ||
'demo-mode' ||
'signals-only' ||
'paper-forex' ||
'alt5' ||
'bitfinex' ||
'binance' ||
'bittrex' ||
'bitstamp' ||
'gemini' ||
'kraken' ||
'liquid'
}
symbol={currentSymbol}
width={500}
/>
);
Note:
brokerName could be one of the following and it will return a Sentiment Graph:
- Traditional Brokerages
demo-mode
simulation-mode
signals-only
paper-forex
- Digital Exchanges
bitfinex
binance
bittrex
bitstamp
gemini
kraken
liquid