For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See: http://commonmark.org/help/
Can't find the folder
-
Although my folder is in the correct path, the function can't find it.
I am new relatively new to programming, maybe some obvious mistakes?
import backtrader as bt cerebro = bt.Cerebro() data = bt.feeds.GenericCSVData(dataname='D:\Programme\Visual Studio Code\Projekte\D_Candles.csv', dtformat=2) cerebro.adddata(data) cerebro.run() cerebro.plot()
All dependencies and packages were installed.
Error Message:
Traceback (most recent call last): line 9, in <module> cerebro.run() line 1127, in run runstrat = self.runstrategies(iterstrat) line 1210, in runstrategies data._start() line 203, in _start self.start() line 88, in start super(GenericCSVData, self).start() line 674, in start self.f = io.open(self.p.dataname, 'r') FileNotFoundError: [Errno 2] No such file or directory: 'D_Candles.csv' PS D:\Programme\Visual Studio Code\Projekte>
What I tried so far:
- just tiping the folder name
- switching the backslashes
- copied the folder in an other path
- changed the folders name
I really appreciate your help.
Even if you know an alternative function I could try...