head	1.12;
access;
symbols
	pkgsrc-2026Q1:1.12.0.4
	pkgsrc-2026Q1-base:1.12
	pkgsrc-2025Q4:1.12.0.2
	pkgsrc-2025Q4-base:1.12
	pkgsrc-2025Q3:1.11.0.2
	pkgsrc-2025Q3-base:1.11
	pkgsrc-2025Q2:1.10.0.6
	pkgsrc-2025Q2-base:1.10
	pkgsrc-2025Q1:1.10.0.4
	pkgsrc-2025Q1-base:1.10
	pkgsrc-2024Q4:1.10.0.2
	pkgsrc-2024Q4-base:1.10
	pkgsrc-2024Q3:1.9.0.10
	pkgsrc-2024Q3-base:1.9
	pkgsrc-2024Q2:1.9.0.8
	pkgsrc-2024Q2-base:1.9
	pkgsrc-2024Q1:1.9.0.6
	pkgsrc-2024Q1-base:1.9
	pkgsrc-2023Q4:1.9.0.4
	pkgsrc-2023Q4-base:1.9
	pkgsrc-2023Q3:1.9.0.2
	pkgsrc-2023Q3-base:1.9
	pkgsrc-2023Q2:1.7.0.10
	pkgsrc-2023Q2-base:1.7
	pkgsrc-2023Q1:1.7.0.8
	pkgsrc-2023Q1-base:1.7
	pkgsrc-2022Q4:1.7.0.6
	pkgsrc-2022Q4-base:1.7
	pkgsrc-2022Q3:1.7.0.4
	pkgsrc-2022Q3-base:1.7
	pkgsrc-2022Q2:1.7.0.2
	pkgsrc-2022Q2-base:1.7
	pkgsrc-2022Q1:1.6.0.2
	pkgsrc-2022Q1-base:1.6
	pkgsrc-2021Q4:1.3.0.6
	pkgsrc-2021Q4-base:1.3
	pkgsrc-2021Q3:1.3.0.4
	pkgsrc-2021Q3-base:1.3
	pkgsrc-2021Q2:1.3.0.2
	pkgsrc-2021Q2-base:1.3
	pkgsrc-2021Q1:1.2.0.16
	pkgsrc-2021Q1-base:1.2
	pkgsrc-2020Q4:1.2.0.14
	pkgsrc-2020Q4-base:1.2
	pkgsrc-2020Q3:1.2.0.12
	pkgsrc-2020Q3-base:1.2
	pkgsrc-2020Q2:1.2.0.10
	pkgsrc-2020Q2-base:1.2
	pkgsrc-2020Q1:1.2.0.6
	pkgsrc-2020Q1-base:1.2
	pkgsrc-2019Q4:1.2.0.8
	pkgsrc-2019Q4-base:1.2
	pkgsrc-2019Q3:1.2.0.4
	pkgsrc-2019Q3-base:1.2
	pkgsrc-2019Q2:1.2.0.2
	pkgsrc-2019Q2-base:1.2
	pkgsrc-2019Q1:1.1.0.8
	pkgsrc-2019Q1-base:1.1
	pkgsrc-2018Q4:1.1.0.6
	pkgsrc-2018Q4-base:1.1
	pkgsrc-2018Q3:1.1.0.4
	pkgsrc-2018Q3-base:1.1
	pkgsrc-2018Q2:1.1.0.2
	pkgsrc-2018Q2-base:1.1;
locks; strict;
comment	@# @;


1.12
date	2025.10.09.07.57.38;	author wiz;	state Exp;
branches;
next	1.11;
commitid	t4nMY0Dt3rBjSRdG;

1.11
date	2025.07.03.19.18.04;	author wiz;	state Exp;
branches;
next	1.10;
commitid	VtH4NTLuuL94Nk1G;

1.10
date	2024.10.14.06.45.43;	author wiz;	state Exp;
branches;
next	1.9;
commitid	ynDJEEQamKd33BtF;

1.9
date	2023.08.01.23.20.42;	author wiz;	state Exp;
branches;
next	1.8;
commitid	lyjXpsSeA6xpH8zE;

1.8
date	2023.07.01.08.37.34;	author wiz;	state Exp;
branches;
next	1.7;
commitid	OGZpaIgVtdY8O4vE;

1.7
date	2022.04.10.14.42.18;	author nia;	state Exp;
branches;
next	1.6;
commitid	WPw7wqCOsEp4cFzD;

1.6
date	2022.01.05.15.41.10;	author wiz;	state Exp;
branches;
next	1.5;
commitid	FQ77UruBIUsgzsnD;

1.5
date	2022.01.04.20.53.52;	author wiz;	state Exp;
branches;
next	1.4;
commitid	CYyhdK9qtoffkmnD;

1.4
date	2021.12.30.13.05.32;	author adam;	state Exp;
branches;
next	1.3;
commitid	w23rFuQ4pTWhUFmD;

1.3
date	2021.04.09.15.42.35;	author tnn;	state Exp;
branches;
next	1.2;
commitid	auXoQZkKOrN8iDOC;

1.2
date	2019.06.17.05.43.02;	author adam;	state Exp;
branches;
next	1.1;
commitid	LyWGlIBxNgWyfvrB;

1.1
date	2018.05.12.22.06.53;	author minskim;	state Exp;
branches;
next	;
commitid	irWQdCQDNj5CA3CA;


desc
@@


1.12
log
@*: remove reference to (removed) Python 3.9
@
text
@# $NetBSD: Makefile,v 1.11 2025/07/03 19:18:04 wiz Exp $

DISTNAME=	backtrader-1.9.74.123
PKGNAME=	${PYPKGPREFIX}-${DISTNAME}
PKGREVISION=	2
CATEGORIES=	finance python
#MASTER_SITES=	${MASTER_SITE_PYPI:=b/backtrader/}
MASTER_SITES=	${MASTER_SITE_GITHUB:=mementum/}
GITHUB_PROJECT=	backtrader

MAINTAINER=	minskim@@NetBSD.org
HOMEPAGE=	https://github.com/mementum/backtrader
COMMENT=	Python Backtesting library for trading strategies
LICENSE=	gnu-gpl-v3

DEPENDS+=	${PYPKGPREFIX}-matplotlib-[0-9]*:../../graphics/py-matplotlib
DEPENDS+=	${PYPKGPREFIX}-numpy-[0-9]*:../../math/py-numpy
DEPENDS+=	${PYPKGPREFIX}-pandas-[0-9]*:../../math/py-pandas

USE_LANGUAGES=	# none

USE_PKG_RESOURCES=	yes

PYTHON_VERSIONS_INCOMPATIBLE=	310

post-install:
	cd ${DESTDIR}${PREFIX}/bin && \
	${MV} bt-run.py bt-run-${PYVERSSUFFIX}.py && \
	${MV} btrun btrun-${PYVERSSUFFIX} || ${TRUE}

.include "../../lang/python/egg.mk"
.include "../../mk/bsd.pkg.mk"
@


1.11
log
@*: py-numpy needs Python >= 3.11 now
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.10 2024/10/14 06:45:43 wiz Exp $
d24 1
a24 1
PYTHON_VERSIONS_INCOMPATIBLE=	39 310
@


1.10
log
@*: clean-up after python38 removal
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.9 2023/08/01 23:20:42 wiz Exp $
d24 2
@


1.9
log
@*: remove more references to Python 3.7
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.8 2023/07/01 08:37:34 wiz Exp $
a21 2
PYTHON_VERSIONS_INCOMPATIBLE=	27 38

@


1.8
log
@*: restrict py-numpy users to 3.9+ in preparation for update
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.7 2022/04/10 14:42:18 nia Exp $
d22 1
a22 1
PYTHON_VERSIONS_INCOMPATIBLE=	27 37 38
@


1.7
log
@Paper over tree breakage caused by unresolvable Python deps from
scikit/pandas/numpy.
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.6 2022/01/05 15:41:10 wiz Exp $
d22 1
a22 1
PYTHON_VERSIONS_INCOMPATIBLE=	27 37 # py-matplotlib, py-pandas
@


1.6
log
@python: egg.mk: add USE_PKG_RESOURCES flag

This flag should be set for packages that import pkg_resources
and thus need setuptools after the build step.

Set this flag for packages that need it and bump PKGREVISION.
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.5 2022/01/04 20:53:52 wiz Exp $
d22 1
a22 1
PYTHON_VERSIONS_INCOMPATIBLE=	27 # py-matplotlib, py-pandas
@


1.5
log
@*: bump PKGREVISION for egg.mk users

They now have a tool dependency on py-setuptools instead of a DEPENDS
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.4 2021/12/30 13:05:32 adam Exp $
d5 1
a5 1
PKGREVISION=	1
d24 2
@


1.4
log
@Forget about Python 3.6
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.3 2021/04/09 15:42:35 tnn Exp $
d5 1
@


1.3
log
@propagate python incompatibilities
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.2 2019/06/17 05:43:02 adam Exp $
d21 1
a21 1
PYTHON_VERSIONS_INCOMPATIBLE=	36 27	# py-matplotlib, py-pandas
@


1.2
log
@py-backtrader: updated to 1.9.74.123

1.9.74.123:
  - Correct calculation in haDelta indicator
  - Use initial datalabel for non-overlaid volume plot

1.9.73.123:
  - Add utility NonZeroDifference indicator
  - Redefine CrossUp, CrossDown and CrossOver indicators using
    NonZeroDifference to cover the case in which the crossing entities
    converge right before crossing up and down

1.9.72.122:
  - Cover case in which result in high-level overridden operations have
    multiple lines and wer not be taken into account for minimum period
    calculations
  - Add "Int" variants of percentage based sizers to import
  - Trades observer to show net profit instead of brutto, with parameter
    to control behavior

1.9.71.122:
  - Improve on indicator legend plotting to overcome matplotlib legend
    reordering
  - Added PercenSizerInt and AllSizerInt which truncate the returned size
    to an int, suited better for stocks/futures

1.9.70.122:
  - Use opening price for submission check for Market orders when
    cheat-on-open is active
  - Update pnlcomm on all operations and not just profit/loss locking
  - Correct comment for fillalpha and add baralpha for candlestick opacity
  - Use internal dict for data feed presence test and update trade observer

1.9.69.122:
  - Fix offline Yahoo feed by moving the new adjclose line up to the offline
    feed
  - Adapt the yahoodownload tool to the current status (ex: data not reversed)
  - Redownload all yahoo data feeds

1.9.68.122
  - Fix call to _nextday in TradingCalendar
  - Clean up and rework of Yahoo Data. The data feeds seems to be reliable
    again
  - IBStore Support for IND prices

1.9.67.122
  - Fix compression only scenarios when resampling and resampling after
    changes in 1.9.66.122
  - Final correction for rollover fix introduced in 1.9.66.122
  - Cover use case for mininum period calculation when all
    operations/indicators don't use the data feeds directly but lines of it

1.9.66.122
  - Fix regression introduced with 8f537a1c2c271eb5cfc592b373697732597d26d6
    which voids the count of lost trades
  - Allow rollover to distinguish between no values temporarily (with None)
    and no values permanently (with False)
  - Avoid math domain error for negative returns in logarithmic calculations
  - Fix local variable declaration for compound returns
  - Fix typo in date2num tz conversion which shows up in direct usage

1.9.65.122
  - Fix commission info assigment and orderref seeking in OandaStore
  - Add strategy type to OptReturn
  - Fix prepend_constant for OLS_Transformation
  - Fix LogReturnsRolling compression when not specified
  - Have ints instead of bools in some values with 1 Trade in TradeAnalyzer

1.9.64.122
  - Avoid stage2 comparison using [0] in API methods
  - Support plotname, if given, as name of indicator in csv output

1.9.63.122
  - Add optimization callbacks when running with 1 Core
  - Correct sell_bracket by removing old append code
  - Correct typo in store.py
  - Pass period from RateOfChange100 to underlying ROC

1.9.62.122
  - Correct PSAR acceleration capping
  - Enable PandasData line extension without the need to extend datafields

1.9.61.122
  - Add `_skipnan` to plotlines to allow joining two points with a line
  - buy_bracket/sell_bracket allow suppressing stop/limit orders
  - Add stop-loss approaches sample
  - Correct codes for minutes compression

1.9.60.122
  - Remove unused files
  - README update, Docstring corrections, documentation corrections
  - Update travis settings

1.9.58.122
  - Provide default fundmode methods for all brokers
  - Correct order notification if positions exist when starting the broker
    and will be simulated
  - Correct csv values output if object has no length

1.9.57.122
  - Fix set_fundmode in bbroker
  - Synchronize fund history mode with master clock
  - Allow relocation of legend in plotting charts
  - Adapt broker observer to fund mode

1.9.56.122
  - Handle volume as string null in YahooFinanceData
  - Corrections/Improvements to order history support
  - Add fund history support
  - Increase plotting margin of trade observers
@
text
@d1 1
a1 1
# $NetBSD: Makefile,v 1.1 2018/05/12 22:06:53 minskim Exp $
d21 1
a21 1
PYTHON_VERSIONS_INCOMPATIBLE=	27	# py-matplotlib
@


1.1
log
@finance/py-backtrader: Import version 1.9.58.122

Backtrader is a feature-rich Python framework for backtesting and
trading. It allows you to focus on writing reusable trading
strategies, indicators and analyzers instead of having to spend time
building infrastructure.
@
text
@d1 1
a1 1
# $NetBSD$
d3 1
a3 1
DISTNAME=	backtrader-1.9.58.122
d6 1
a8 1
GITHUB_TAG=	${PKGVERSION_NOREV}
d19 3
a21 1
.include "../../lang/python/egg.mk"
d24 3
a26 4
.for f in bt-run.py btrun
	${MV} ${DESTDIR}${PREFIX}/bin/${f} \
		${DESTDIR}${PREFIX}/bin/${f}${PYVERSSUFFIX}
.endfor
d28 1
@

