intenvget
Properties of interest-rate structure
Description
obtains the value of the named parameter ParameterValue
= intenvget(RateSpec
,ParameterName
)ParameterName
extracted from the RateSpec
.
Examples
Extract Values from a RateSpec
Use intenvset
to set the interest-rate structure.
RateSpec = intenvset('Rates',0.05,'StartDates',... '20-Jan-2000','EndDates','20-Jan-2001')
RateSpec = struct with fields:
FinObj: 'RateSpec'
Compounding: 2
Disc: 0.9518
Rates: 0.0500
EndTimes: 2
StartTimes: 0
EndDates: 730871
StartDates: 730505
ValuationDate: 730505
Basis: 0
EndMonthRule: 1
Use intenvget
to extract values from the RateSpec
.
[R, RateSpec] = intenvget(RateSpec,'Rates')
R = 0.0500
RateSpec = struct with fields:
FinObj: 'RateSpec'
Compounding: 2
Disc: 0.9518
Rates: 0.0500
EndTimes: 2
StartTimes: 0
EndDates: 730871
StartDates: 730505
ValuationDate: 730505
Basis: 0
EndMonthRule: 1
Input Arguments
RateSpec
— Interest-rate specification
structure
Interest-rate specification, specified by the RateSpec
obtained previously from intenvset
or toRateSpec
for an
IRDataCurve
or toRateSpec
for an
IRFunctionCurve
.
Data Types: struct
ParameterName
— Parameter name to be accessed
character vector
Parameter name to be accessed, specified as a character vector. The value
of the named parameter is extracted from the structure
RateSpec
. It is sufficient to type only the leading
characters that uniquely identify the parameter. Case is ignored for
parameter names.
Data Types: char
Output Arguments
ParameterValue
— Value of the named parameter ParameterName
extracted from RateSpec
scalar
Value of the named parameter 'ParameterName'
extracted
from RateSpec
, returned as a scalar value.
Version History
Introduced before R2006a
Comando MATLAB
Hai fatto clic su un collegamento che corrisponde a questo comando MATLAB:
Esegui il comando inserendolo nella finestra di comando MATLAB. I browser web non supportano i comandi MATLAB.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)