Skip to content

Commit

Permalink
Merge pull request IDEMSInternational#9128 from Fidel365/probkeyboard
Browse files Browse the repository at this point in the history
Improvements to the pnorm key in Probability keyboard, and adding missing tooltips in the Calculator
  • Loading branch information
N-thony authored Sep 9, 2024
2 parents 32e3272 + 9b6a85f commit 47f3236
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions instat/ucrCalculator.vb
Original file line number Diff line number Diff line change
Expand Up @@ -266,9 +266,10 @@ Public Class ucrCalculator
ttCalculator.SetToolTip(cmdNthPrime, "gives the n-th prime. For example nth_prime(1000)= 7919")
ttCalculator.SetToolTip(cmdGeneratePrimes, "generates the first n prime numbers equal to the number of rows in the data")
ttCalculator.SetToolTip(cmdGCD, "greatest common divisor, for example gcd(18,42) = 6")
ttCalculator.SetToolTip(cmdSCM, "smallest common multiple, for example scm(18,42) = 126 (= 718 & 342)")
ttCalculator.SetToolTip(cmdCoprime, "also called mutually prime, for example coprime(30,77) = TRUE. (30 = 235, 77 = 7*11)")
ttCalculator.SetToolTip(cmdPhi, "Euler’s Totient Function. For example phi(12) = 4 (1, 2, 5, 7 are less than 12 and coprime)")
ttCalculator.SetToolTip(cmdReverseStr, "reverses a string. So reverse(""I am roger"") becomes ""regor ma I""")
ttCalculator.SetToolTip(cmdSCM, "smallest common multiple, for example scm(18,42) = 126(= 718 & 342)")
ttCalculator.SetToolTip(cmdCoprime, "also called mutually prime, For example coprime(30,77) = True. (30 = 235, 77 = 7*11)")
ttCalculator.SetToolTip(cmdPhi, "Euler's Totient Function. For example phi(12) = 4 (1, 2, 5, 7 are less than 12 and coprime)")
ttCalculator.SetToolTip(cmdTwin, "twin primes, for example, twin(0,10) gives (3,5), & (5,7)")
ttCalculator.SetToolTip(cmdCousin, "cousin primes, for example cousin(0,20) gives (3,7) & (13,17)")
ttCalculator.SetToolTip(cmdSexy, "sexy primes (6 in Latin is sex!), for example sexy(0,40) gives (23,29) & (31,37)")
Expand All @@ -279,14 +280,15 @@ Public Class ucrCalculator
ttCalculator.SetToolTip(cmdPalindrome, "generates palindromes to the length of the dataframe. For example the 100th palindromic number is 909")
ttCalculator.SetToolTip(cmdCatalan, "generates Catalan numbers to the length of the data frame. The 5th is 10!/(5!*6!) =7 * 6 = 42")
ttCalculator.SetToolTip(cmdPerfect, "divisors add to the number. So 6 = 1+2+3. Only 51 perfect numbers are currently known.")
ttCalculator.SetToolTip(cmdAbundant, "generates abundant numbers to the length of the data frame. 12 is is the first, because 1+2+3+4+6 > 12")
ttCalculator.SetToolTip(cmdFrugal, "125 is frugal because 125 = 5(cubed) and 5 and 3 are fewer digits (2) than 125 (3).")
ttCalculator.SetToolTip(cmdPowerful, "36 = 2(squared)*3(squared) is powerful because for each divisor, here 2 and 3, its square is also a divisor.")
ttCalculator.SetToolTip(cmdUgly, "also called Regular or Hamming or 5-smooth numbers. Numbers for which the factors are only 2, or 3 or 5.")
ttCalculator.SetToolTip(cmdHappy, "13 is happy because 1(squared) + 3(squared) = 10, then 1(squared)+ 0(squared) = 1.")
ttCalculator.SetToolTip(cmdAchilles, "powerful numbers that are not perfect squares. 72 is the smallest Achilles number.")
ttCalculator.SetToolTip(cmdPadovan, "sum of last but 1 and last but 2 values. So from ...7, 9, 12, next is 7+9 = 16.")
ttCalculator.SetToolTip(cmdPowerful, "36 = 2(squared)*3(squared) is powerful because for each divisor, here 2 and 3, its square is also a divisor")
ttCalculator.SetToolTip(cmdUgly, "also called Regular or Hamming or 5-smooth numbers. Numbers for which the factors are only 2, or 3 or 5")
ttCalculator.SetToolTip(cmdHappy, "13 is happy because 1(squared) + 3(squared) = 10, then 1(squared)+ 0(squared) = 1")
ttCalculator.SetToolTip(cmdAchilles, "powerful numbers that are not perfect squares. 72 is the smallest Achilles number")
ttCalculator.SetToolTip(cmdPadovan, "sum of last but 1 and last but 2 values. So from ...7, 9, 12, next is 7+9 = 16")
ttCalculator.SetToolTip(cmdTriangle, "number of objects in a triangle, so 0, 1, 3, 6, 10...")
ttCalculator.SetToolTip(cmdSquare, "squares of each integer, so 1, 4, 9, 16.")
ttCalculator.SetToolTip(cmdSquare, "squares of each integer, so 1, 4, 9, 16")
ttCalculator.SetToolTip(cmdLucas, "generates Lucas numbers to the length of the dataframe. For example the 10th Lucas number is 76")
ttCalculator.SetToolTip(cmdPrimorial, "gives the primorial (like the factorial, but just the primes up to the number) for a variable. For example primorial(c(7,8,9)) = 235*7 = (210, 210, 210)")

Expand Down Expand Up @@ -1573,7 +1575,7 @@ Public Class ucrCalculator

Private Sub cmdPnorm_Click(sender As Object, e As EventArgs) Handles cmdPnorm.Click
If chkShowParameters.Checked Then
ucrReceiverForCalculation.AddToReceiverAtCursorPosition("pnorm(q= , mean = 0, sd = 1, lower.tail = True, Log.p = False)", 54)
ucrReceiverForCalculation.AddToReceiverAtCursorPosition("pnorm(q= , mean = 0, sd = 1, lower.tail = TRUE, log.p = FALSE)", 54)
Else
ucrReceiverForCalculation.AddToReceiverAtCursorPosition("pnorm( )", 2)
End If
Expand Down

0 comments on commit 47f3236

Please sign in to comment.