(a) Write an R function rnormmax that has three arguments, n, mu, and sigm, # and returns...

50.1K

Verified Solution

Question

Basic Math

(a) Write an R function rnormmax that has three arguments, n,mu, and sigm,
# and returns the maximum of a vector of n random numbers from thenormal distribution
# with mean mu and standard deviation sigm. Make the arguments muand sigm optional
# with default values of 0 and 1, respectively.


# (b) Write an R code that replicates rnormmax(n=1000) hundredthousand times and creates
# a histogram of the resulting vector via standard histfunction.

Answer & Explanation Solved by verified expert
4.3 Ratings (601 Votes)
trnorm100001 t1 02025522364 05628747394 0300829367000109936054 138580620776 10962769079 04107434903 0921360054810035003042 0228765208911 01893576987 03368195312 11492968266 024641018870127507355216 00212622805 11876985396 11493823781 054953498051210711770721 01476249844 05137755952 07154159488 090790264420956129944826 09152880058 00531798150 07805725446 046896276351229516279231 15463529114 13277500555 06857960485 057536458441294673094336 15413879495 24402947504 08391489027 040982283960567406985141 10035146891 00486254537 00215929972 011057038580439443365146 12026577962 08336760830 05495587990 013311795840685656789251 03440381303 01631663831 00949072779 110755491570419417114656 06229146401 00716801413 07113681939 039221193880318703046661 01981484884 01527989123 02197427597 031255549960005816876566 03333864452 08002497373 09048584392 066862760840376906091771 03714546746 10371545897 06211163640 103483075190954722473276 05280907971 18446492578 13593743376 088478385021653157228481 04015734208 02643377498 05787477472 147198157070359493996286 03282870768 05745701271 01798735695 041190144261293226284191 07229004919 04589662382 03662283877 052255284140137893861796 01145632847 03932730051 20932515616 0396693110008927617739101 16354471324 01093359641 02675152310 0545385929805501264148106 05293513730 01408506042 16892246992 0767547247602610344597111 00378232906 13798153285 03157370288 0380309831102124364966116 02849530665 17276265139 03046483811 0773800371802248115092121 02748815879 00361064430 06220237545 0559687863802614530359126 04972331978 12920001635 04705439438 0116602399514252332256131 07089964238 10474221429 06067528331 0940345606313385762767136 05771250379 06278930018 10876027066 0494408522102091250630141 10352714293 14980403551 03706285436 1733590131906673666077146 22803426750 00056788980 02184565331 1225677210104720021056151 18838095431 04832002909 03460169051 1312235534923052494413156 02385604711 18094952747 04648103488 0572712434304854108249161 00909614677 09241014109 05492545344 1716581130614557613700166 01546512044 02759981970 10201058149 0277686961008527108929171 03418175450 00693307020 03225739425 1673946096902265769340176 02802373394 00673886795 02604722815 0765491962300497559056181 00387649155 15625207710 04624629431 0379927833609715111231186 12477611681 03748317460 02773003468 0818999998502405951842191 29023942032 04289912594 08790687109 0122590203210734815627196 08889225905 11138304904 04893193643 0351940289500532397498201    See Answer
Get Answers to Unlimited Questions

Join us to gain access to millions of questions and expert answers. Enjoy exclusive benefits tailored just for you!

Membership Benefits:
  • Unlimited Question Access with detailed Answers
  • Zin AI - 3 Million Words
  • 10 Dall-E 3 Images
  • 20 Plot Generations
  • Conversation with Dialogue Memory
  • No Ads, Ever!
  • Access to Our Best AI Platform: Flex AI - Your personal assistant for all your inquiries!
Become a Member

Other questions asked by students