tea-bond 0.3.8__cp310-abi3-win_amd64.whl → 0.3.9__cp310-abi3-win_amd64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of tea-bond might be problematic. Click here for more details.

pybond/pd.py CHANGED
@@ -24,9 +24,9 @@ class TfEvaluators:
24
24
  future: str | pd.Series,
25
25
  bond: str | pd.Series,
26
26
  date: str | pd.Series,
27
- future_price: pd.Series,
28
- bond_ytm: pd.Series,
29
- capital_rate: float | pd.Series,
27
+ future_price: pd.Series | None = None,
28
+ bond_ytm: pd.Series | None = None,
29
+ capital_rate: float | pd.Series | None = None,
30
30
  reinvest_rate: float | None = None,
31
31
  ):
32
32
  """
@@ -51,7 +51,12 @@ class TfEvaluators:
51
51
  "capital_rate": capital_rate,
52
52
  }
53
53
  )
54
- self._evaluators = PlTfEvaluators(reinvest_rate=reinvest_rate)
54
+ self._evaluators = PlTfEvaluators(
55
+ future_price="future_price",
56
+ bond_ytm="bond_ytm",
57
+ capital_rate="capital_rate",
58
+ reinvest_rate=reinvest_rate,
59
+ )
55
60
 
56
61
  @property
57
62
  def net_basis_spread(self):
pybond/pl.py CHANGED
@@ -19,9 +19,9 @@ class TfEvaluators:
19
19
  future: IntoExpr = "future",
20
20
  bond: IntoExpr = "bond",
21
21
  date: IntoExpr = "date",
22
- future_price: IntoExpr = "future_price",
23
- bond_ytm: IntoExpr = "bond_ytm",
24
- capital_rate: IntoExpr = "capital_rate",
22
+ future_price: IntoExpr = None,
23
+ bond_ytm: IntoExpr = None,
24
+ capital_rate: IntoExpr = None,
25
25
  reinvest_rate=None,
26
26
  ):
27
27
  """
@@ -36,16 +36,24 @@ class TfEvaluators:
36
36
  capital_rate: Capital cost rate column expression
37
37
  reinvest_rate: Reinvestment rate (optional)
38
38
  """
39
- if future is None:
40
- future = pl.lit(None).cast(str)
41
- if bond is None:
42
- bond = pl.lit(None).cast(str)
43
- self.future = parse_into_expr(future)
44
- self.bond = parse_into_expr(bond)
45
- self.date = parse_into_expr(date)
46
- self.future_price = parse_into_expr(future_price)
47
- self.bond_ytm = parse_into_expr(bond_ytm)
48
- self.capital_rate = parse_into_expr(capital_rate)
39
+ self.future = parse_into_expr(
40
+ future if future is not None else pl.lit(None).cast(str)
41
+ )
42
+ self.bond = parse_into_expr(
43
+ bond if bond is not None else pl.lit(None).cast(str)
44
+ )
45
+ self.date = parse_into_expr(
46
+ date if date is not None else pl.lit(None).cast(pl.Date)
47
+ )
48
+ self.future_price = parse_into_expr(
49
+ future_price if future_price is not None else pl.lit(None)
50
+ )
51
+ self.bond_ytm = parse_into_expr(
52
+ bond_ytm if bond_ytm is not None else pl.lit(None)
53
+ )
54
+ self.capital_rate = parse_into_expr(
55
+ capital_rate if capital_rate is not None else pl.lit(None)
56
+ )
49
57
  self.reinvest_rate = reinvest_rate
50
58
 
51
59
  def _call_plugin(self, symbol: str):
pybond/pybond.pyd CHANGED
Binary file
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: tea-bond
3
- Version: 0.3.8
3
+ Version: 0.3.9
4
4
  Classifier: Programming Language :: Rust
5
5
  Classifier: Programming Language :: Python :: Implementation :: CPython
6
6
  Classifier: Programming Language :: Python :: Implementation :: PyPy
@@ -15,12 +15,12 @@ pybond/nb/nb_datetime.py,sha256=sg3Vmg2n2P_A186QgOGSOKBq-Tr72ht_Yw064yYrWXE,1067
15
15
  pybond/nb/nb_duration.py,sha256=bndVSHdG_yV0_vEWeAHd9Lq_UQ-8nkPnEC9cN2A2ca4,1709
16
16
  pybond/nb/nb_evaluators.py,sha256=GBsW3UuGf8iVUWr2DTISXzdYoGV5ITEOVFJivBNmWkc,15544
17
17
  pybond/nb/nb_time.py,sha256=5KNrWYcPwZUHoxvZKvh3qdhjB0DjRkxbUzONSv6OfhY,8928
18
- pybond/pd.py,sha256=SSQdg4hzc9dLN53ICTI65UyAEkAvKnAt98u9EX09IqM,13575
19
- pybond/pl.py,sha256=kB0rxuJjZnD8tm_c5Vmy6iGxmstaB51qzr65M9vR4sA,13706
18
+ pybond/pd.py,sha256=gXUV6d069jC94Ej04njrgQCW16UdYx0Rh9y2IVMc068,13760
19
+ pybond/pl.py,sha256=WhiBv6IOs5-jxK78xd75KXZSogoFyJ0XJ-v23Gjp_ho,13966
20
20
  pybond/pnl.py,sha256=RXC5GnQckD4LmTjgPwCePB-3GxsQ4liu0TW6hSdudLE,2752
21
21
  pybond/polars_utils.py,sha256=020Dy-l6v_NF-y7LXcKyJmWGAgH59NAxWKvjfnJO1tY,2663
22
- pybond/pybond.pyd,sha256=mvYdCwkfJP-GuHltpv2c-Sn8GepMZ5QvEU-PAeUCJd0,23558656
22
+ pybond/pybond.pyd,sha256=q4quLGe7AotoL05c1kGxlUhh5M-ofcFc754CMM8inxE,23570944
23
23
  pybond/pybond.pyi,sha256=qzOfqoysuUW7rnZYxEmGEJXK_UrCjMvQ29Y_mJOBN1Y,11621
24
- tea_bond-0.3.8.dist-info/METADATA,sha256=iFDD8dsw7ptVOSC_aR1cOepgVmUCQVxGKW423JB2BKU,258
25
- tea_bond-0.3.8.dist-info/WHEEL,sha256=G8mq-RexZGAfbjW58CyHDPQ4EbuJINRXbIh22TbaFhw,95
26
- tea_bond-0.3.8.dist-info/RECORD,,
24
+ tea_bond-0.3.9.dist-info/METADATA,sha256=NTcEhk7-WT_aWbCc5fmxZbZecfzQa6O3PB0tozeRyhs,258
25
+ tea_bond-0.3.9.dist-info/WHEEL,sha256=G8mq-RexZGAfbjW58CyHDPQ4EbuJINRXbIh22TbaFhw,95
26
+ tea_bond-0.3.9.dist-info/RECORD,,