code: def test_weighted_std():
      x = np.array([1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0])
      y = np.array([9.0, 8.0, 7.0, 6.0, 5.0, 4.0, 3.0, 2.0, 1.0])
      Sigma = np.cov(x, y)
      weights = np.array([1.0, 1.0])
      assert weighted_std(Sigma, weights) == 0.0
      weights = np.array([-3.0, 5.0])
      assert weighted_std(Sigma, weights) ** 2 == 480.0
  
file_path: FinQuant/tests/test_quants.py
imports: import pdb
  import numpy
  import pandas
  import pytest
  from finquant.quants import annualised_portfolio_quantities, downside_risk, sharpe_ratio, sortino_ratio, treynor_ratio, value_at_risk, weighted_mean, weighted_std
label_desc: Use image node_id 2 for calling a global function with example usage: test_weighted_std() without return types