Mode:
Duration:
1
Coding works best on desktop or with an external keyboard.
Coding works best on desktop or with an external keyboard.
Compute portfolio variance using weights and covariance matrix.
DATA: cov_matrix TYPE STANDARD TABLE OF STANDARD TABLE OF f WITH DEFAULT KEY.
cov_matrix = VALUE #( ( (0.0004 0.0002) (0.0002 0.0003) ) ).
DATA(weights) = VALUE #( (0.6) (0.4) ).
DATA(portfolioVariance) TYPE f.
portfolioVariance = weights[1]*weights[1]*0.0004 + weights[1]*weights[2]*0.0002 + weights[2]*weights[1]*0.0002 + weights[2]*weights[2]*0.0003.
WRITE: / 'Portfolio Variance:', portfolioVariance.SAP ABAP (Advanced Business Application Programming) is a high-level programming language developed by SAP for building enterprise applications on SAP systems, enabling customization, data processing, and business workflow automation.
Origin & Creator
Developed by SAP SE, Germany, originally in the 1980s for SAP R/2 and later SAP R/3 systems.
Industrial Note
Extensively used in enterprise software development, SAP module customization, and large-scale business process automation.