Talk:Documentation/Calc Functions/TBILLPRICE

    From The Document Foundation Wiki

    SF Comments

    (1) Summary. Suggest replacing with the following – “Calculates the issue price for a US Treasury bill, per 100 currency units par value (face value), given a discount rate”.
    (2) Returns. Suggest replacing with the following – “Returns a real number (in currency units) which is the issue price for a US Treasury bill per 100 currency units par value, for the given arguments.”.
    (3) Arguments, Settlement. Change “date of purchase of the security” to “settlement / purchase date of the Treasury bill”.
    (4) Arguments, Maturity. Change “date on which the security matures (expires)” to “the maturity / redemption date of the Treasury bill”.
    (5) Arguments, Discount. Change “discount of security” to “discount rate of the Treasury bill, expressed”. Insert “decimal” before “fraction”.
    (6) Arguments, 1st bullet. Suggest replacing with “If either Settlement or Maturity is not a valid date then the function returns a value (#VALUE!) error”.
    (7) Arguments, 2nd bullet. Insert “the” before “Settlement”.
    (8) Additional details. Suggest adding link to the Wikipedia page at https://en.wikipedia.org/wiki/United_States_Treasury_security#Treasury_bill.
    (9) Additional details. Suggest including the following paragraph – “A US Treasury bill (often shortened to T-bill) is a short term (up to a year) government security, sold at a discount to its par value (face value). It pays no interest and is redeemed at par value. The Treasury bill has a 360-day year basis.”.
    (10) Additional details. I have checked the code and the equation for this function is TBILLPRICE = 100 x (1 – (Discount x DSM)/360) where DSM is defined as for TBILLEQ.
    (11) Additional details. It might be worth including a comment that the underlying formula for this function may not apply to Treasury bills issued by other governments.
    (12) Examples, 1st example. Change “9 per cent” to “9.14 per cent”. Change “price of the treasury bill” to “issue price for a US Treasury bill, per 100 currency units par value,”.
    (13) Examples, 3rd example. Insert “the” before “Settlement”.
    (14) ODF standard section. The ODF states that the maturity date should be less than one year beyond the settlement date. However this limitation is not enforced in the code – try, for example, the formula =TBILLPRICE("1999-03-31","2001-06-01", 0.0914). This formula produces a numeric answer in Calc but generates an error in Excel. We perhaps ought to note this discrepancy and, when I get a chance, I will raise a bug.

    --Stevefanning (talk) 2020-11-27T15:34:05 (UTC)