| Ticket UUID: | e6b26853885c35d26243793e917107fa6f47206d | |||
| Title: | proportional weighted shares | |||
| Type: | Patch | Version: | 8.6 | |
| Submitter: | anonymous | Created on: | 2018-08-06 23:17:21 | |
| Subsystem: | math :: statistics | Assigned To: | arjenmarkus | |
| Priority: | 5 Medium | Severity: | Cosmetic | |
| Status: | Open | Last Modified: | 2019-04-18 19:34:02 | |
| Resolution: | None | Closed By: | nobody | |
| Closed on: | ||||
| Description: |
::math::stats::proportional_weighted_shares --
#
# Return the proportional_weighted_shares from quantity by two or more given ratios
#
# Arguments:
# quantity first value is quantity
# args second, third, and sucessive values
# are two or more given ratios (usually integers in high school)
# However, decimal fractions for both quantity and args seem
# to be reasonably accurate to TCL precison.
# Conditions and answer checks
# The quantity must be larger than 0
# The number of args must be larger than 2
# If sum of parts equals zero, formula is undefined
# Number of parts should be equal to [ llength $args ]
# Total value of parts should be equal to quantity entry
# The solution may not be unique in that more than one
# set of shares may have or generate the same multiple ratios.
# Results: parts of quantity into proportional weighted shares
| |||
| User Comments: |
arjenmarkus added on 2019-04-18 19:34:02:
I will create a new package for this proc and the ticket regarding combined_market_rate. These are fairly specialised algorithms and to make them recognisable, I think a "market" package would be better than merely putting them in one of the existing packages. | |||
Attachments:
- weighted proportional shares diagnostics output.txt [download] added by anonymous on 2018-08-06 23:28:55. [details]
- proportional_weighted_shares_good_diagnostic_version_submit_TCLLIB_math_stats.txt [download] added by anonymous on 2018-08-06 23:23:10. [details]
- proportional_weighted_shares_for_submit_TCLLIB_math_stats.tcl [download] added by anonymous on 2018-08-06 23:21:06. [details]
