Questions tagged [lightweight-charts]

Lightweight Charts is a JavaScript library created by TradingView for displaying financial charts.

Lightweight Charts is a JavaScript library created by TradingView for displaying financial charts.

126 questions
1
vote
2 answers

How to remove the price line in light-weight-chart?

I have implemented tradingview's lightweight chart in my app, and the chart looks like this. There is a dotted horizontal line for the last price. Is it possible to hide the horizontal line?
1
vote
0 answers

How to utilize Lightweight Charts library in flutter using webview

I am interested in using the Lightweight Charts in flutter potentially using webview. Here's an example of code that I want to be integrated. https://jsfiddle.net/TradingView/qrb9a850/ Javascript code: function createSimpleSwitcher(items,…
1
vote
0 answers

Renko/Tick Charts with tradingviews lightweight-chart

I have a data source for candlestick data that is tick-based which means sometimes the timestamp of a bar can be the same. When trying to add the tick-based chart data to the candlestickSeries when one of the tick candles has a timestamp that's the…
NomNomCameron
  • 419
  • 5
  • 14
1
vote
2 answers

Adding annotations to tradingview / lightweight-charts

I would like to add annotations(you could say it's a text note) to the tradingview as shown in the following picture. I tried to use series marker. but, it bothers me that I can't add & design a box that wraps around text. And I don't want to use…
mr5
  • 281
  • 1
  • 3
  • 5
1
vote
2 answers

A way to set PriceScale width in Lightweight charts?

I have two charts (one for price, one for volume). I keep them in sync by usingthe various API observer functions. Works wonders. Except the price scale width - I can get it using the priceScale('right').width() call, but I don't see any way to set…
Segolene
  • 35
  • 8
1
vote
1 answer

Can Lightweight Charts handle large datasets - like 1.2 millions bar candle timeseries?

I am planning to migrate my candle bar timeseries visualization from Plotly to Lightweight Charts. My dataset resides in a database and it includes 1. 2 millions of bar candle timeseries. Can Lightweight Charts handle large datasets - like 1.2…
Allan Xu
  • 7,998
  • 11
  • 51
  • 122
1
vote
1 answer

Draw one day area chart using lightweight-chart library

I am trying to plot stock price data for a ticker using lightweight-charts.I can use it in expected way to draw chart for intervals like 1w, 1 month or 3 month etc. But Chart is not drawn as expected for one-day data. Here are my part of code…
Kanhaiya
  • 359
  • 2
  • 11
1
vote
1 answer

How can i make chart to show price in range?

I am using lightweight-charts for drawing financial charts for stock data. A part of code for drawing chart is: useEffect(() => { if (ref.current) { ref.current.innerHTML = ""; const chart = createChart(ref.current,…
Kanhaiya
  • 359
  • 2
  • 11
1
vote
2 answers

fitContent(); for rightPriceScale - lightweight-charts

is there any way to fitContent for right price scale in lightweight charts? I did not find any info for that in documentation. I am trying to display two data series, but they are in different ranges (tens of thousands vs tens) Here is my jsfiddle.…
Dominik Novotný
  • 336
  • 1
  • 16
1
vote
1 answer

Tradingview Lightweight candlestick charts price depth

I'm building a candlestick chart with preset of price data. By default it is set to two decimals 0.01 of price. However my price data ranges way past from 0.01 to 0.0000002 etc. I'm trying to implement priceFormat property but it doesn't work. Thank…
1
vote
1 answer

How to add Tradingview's Lightweight-charts to React Typescript

I tried installing Tradingview's 'lightweight-charts' for react typescript but I can't seem to download the @types for this package because it does not show up on package.json. Therefore, unable to render my react app. I have tried installing with…
1
vote
0 answers

React and Lightweight Charts - Uncaught TypeError: Cannot read property 'getContext' of null

EDIT: Link to repro on Codesandbox: https://codesandbox.io/s/exciting-worker-f5j1b I need help with an error I am getting every time I am attempting to inject new data into my chart (using lightweight charts) in React. I suspect that the problem is…
1
vote
1 answer

Can't show all data on Lightweight Chart when chart is small, is it expected?

Not sure if it's a limitation or not but I can't make chart display all data (I have 1500 records). fitContent() or setVisibleRange() doesn't help. Demo var chart = LightweightCharts.createChart(document.body, { width: 600, height: 300, …
dtanp
  • 15
  • 3
1
vote
1 answer

How to format reference line in lightweight charts?

How to format reference line in lightweight charts? Following is lightweight chart. As you can se the horizontal line market (US$449,308,044) is taking so much space. Is there a way to format this text? var chart = createChart(ref.current, { …
mx_code
  • 2,441
  • 1
  • 12
  • 37
1
vote
1 answer

Component duplicates when dispatching an action via redux

So I have written some code to display a chart and I have also written a function which will allow me to change the timeframe of the chart. However, when this function is invoked, a duplicate chart pops up. Here is the Chart.js let chartProperties =…
1 2
3
8 9