voly 0.0.59__py3-none-any.whl → 0.0.61__py3-none-any.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.
voly/client.py CHANGED
@@ -319,7 +319,7 @@ class VolyClient:
319
319
  # -------------------------------------------------------------------------
320
320
 
321
321
  @staticmethod
322
- def fit_model(market_data: pd.DataFrame,
322
+ def fit_model(option_chain: pd.DataFrame,
323
323
  model_name: str = 'svi',
324
324
  initial_params: Optional[List[float]] = None,
325
325
  param_bounds: Optional[Tuple] = None) -> Dict[str, Any]:
@@ -327,25 +327,28 @@ class VolyClient:
327
327
  Fit a volatility model to market data.
328
328
 
329
329
  Parameters:
330
- - market_data: DataFrame with market data
330
+ - option_chain: DataFrame with option market data
331
331
  - model_name: Name of model to fit (default: 'svi')
332
332
  - initial_params: Optional initial parameters for optimization
333
333
  - param_bounds: Optional parameter bounds for optimization
334
334
 
335
335
  Returns:
336
- - Dictionary with fitting results and optional plots
336
+ - Tuple of (fit_results, fit_performance)
337
337
  """
338
338
  logger.info(f"Fitting {model_name.upper()} model to market data")
339
339
 
340
340
  # Fit the model
341
- fit_results = fit_model(
341
+ fit_results, fit_performance = fit_model(
342
342
  market_data=market_data,
343
343
  model_name=model_name,
344
344
  initial_params=initial_params,
345
345
  param_bounds=param_bounds
346
346
  )
347
347
 
348
- return fit_results
348
+ return {
349
+ 'fit_results': fit_results,
350
+ 'fit_performance': fit_performance
351
+ }
349
352
 
350
353
  @staticmethod
351
354
  def get_iv_surface(fit_results: Dict[str, Any],
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: voly
3
- Version: 0.0.59
3
+ Version: 0.0.61
4
4
  Summary: Options & volatility research package
5
5
  Author-email: Manu de Cara <manu.de.cara@gmail.com>
6
6
  License: MIT
@@ -1,5 +1,5 @@
1
1
  voly/__init__.py,sha256=8xyDk7rFCn_MOD5hxuv5cxxKZvBVRiSIM7TgaMPpwpw,211
2
- voly/client.py,sha256=zOYgZA0TTJ5bHDCBWqEyeaQ0IKuee1uAIbzk0uyW_Uw,20350
2
+ voly/client.py,sha256=JzxVZSmb71zcB7JGicYZM-NA_gC7Jedu2SOYImxXSNY,20452
3
3
  voly/exceptions.py,sha256=PBsbn1vNMvKcCJwwJ4lBO6glD85jo1h2qiEmD7ArAjs,92
4
4
  voly/formulas.py,sha256=Xgaq4lx1fNzRfu9W84fMNeH6GRJ0FNFNUUUYn5ffjjE,8843
5
5
  voly/models.py,sha256=LXXIlpXZQEfXTuCngxC8Hd3bWtw6wdXDCSGxTLmHM-c,3659
@@ -11,8 +11,8 @@ voly/core/interpolate.py,sha256=ztVIePJZOh-CIbn69wkh1JW2rKywNe2FEewRN0zcSAo,8185
11
11
  voly/core/rnd.py,sha256=8FTU-Qp9epW9yE4XSOdiFGIRXrGyXqF6mVgZn1NMvxk,11813
12
12
  voly/utils/__init__.py,sha256=E05mWatyC-PDOsCxQV1p5Xi1IgpOomxrNURyCx_gB-w,200
13
13
  voly/utils/logger.py,sha256=4-_2bVJmq17Q0d7Rd2mPg1AeR8gxv6EPvcmBDMFWcSM,1744
14
- voly-0.0.59.dist-info/LICENSE,sha256=wcHIVbE12jfcBOai_wqBKY6xvNQU5E909xL1zZNq_2Q,1065
15
- voly-0.0.59.dist-info/METADATA,sha256=z6kwXaTKNBU4imtpUyRVsWGcNdZyajgwMjXxfUe2DmY,4092
16
- voly-0.0.59.dist-info/WHEEL,sha256=52BFRY2Up02UkjOa29eZOS2VxUrpPORXg1pkohGGUS8,91
17
- voly-0.0.59.dist-info/top_level.txt,sha256=ZfLw2sSxF-LrKAkgGjOmeTcw6_gD-30zvtdEY5W4B7c,5
18
- voly-0.0.59.dist-info/RECORD,,
14
+ voly-0.0.61.dist-info/LICENSE,sha256=wcHIVbE12jfcBOai_wqBKY6xvNQU5E909xL1zZNq_2Q,1065
15
+ voly-0.0.61.dist-info/METADATA,sha256=4yMzNptN7516PzN07OVCD5eFTJYuL7gWFfm9o3l35Y8,4092
16
+ voly-0.0.61.dist-info/WHEEL,sha256=52BFRY2Up02UkjOa29eZOS2VxUrpPORXg1pkohGGUS8,91
17
+ voly-0.0.61.dist-info/top_level.txt,sha256=ZfLw2sSxF-LrKAkgGjOmeTcw6_gD-30zvtdEY5W4B7c,5
18
+ voly-0.0.61.dist-info/RECORD,,
File without changes
File without changes