spiralData.Rd
n-2 points are drawn from a normal distribution with mean=0, sd=1, the points in the final two direction are sampled along a spiral by samping the angle from a normal distribution with mean=0, sd=2*pi (absolute values are used to fix the orientation of the spiral).
spiralData(n, p)
n | sample dimensionality |
---|---|
p | number of sample points to generate |
sample points in matrix format
spiralData(4, 100)#> [,1] [,2] [,3] [,4] #> v -1.238081361 0.23264460 0.130188316 0.108525659 #> v 0.070513462 0.67672143 0.729207688 0.192025594 #> v 0.333709489 -0.58996697 -0.104106369 0.274264084 #> v -0.000818866 0.75462540 0.732925064 0.043085967 #> v -1.847341497 -2.34954650 0.480377989 -0.443459048 #> v -1.265428928 -0.83989224 -0.299111545 0.194134722 #> v -1.640596156 0.57439399 -0.546712032 -1.011752457 #> v 2.151040582 -0.87289778 0.110025485 0.011765268 #> v 0.002609863 -0.53109551 -0.397675643 -1.094719280 #> v -0.829847283 0.96902984 -0.129611665 -0.531763273 #> v 1.385693996 -0.55448948 0.433174801 1.419473767 #> v 0.088123898 -0.42259809 -1.035623396 -0.255437093 #> v 0.529385136 0.38543744 -0.129167517 -0.531961265 #> v 1.469740628 1.81899624 -0.149461625 0.269059183 #> v -0.173500415 -1.63215323 0.518481304 -0.410552415 #> v 0.528358855 -0.98877118 0.545227596 -0.384112024 #> v 0.640145872 -0.91390708 0.032786684 -0.575992580 #> v 2.023079539 -1.26247062 0.095051675 0.187417707 #> v 0.897831088 1.22795184 -0.401925390 -0.239578531 #> v -0.578209119 1.05104601 -0.618764161 1.426208677 #> v 0.192366291 -0.93849573 0.003585319 0.255652164 #> v -0.055305791 0.62080362 0.439989621 -0.473192987 #> v -0.250947225 -0.02732318 0.130744789 0.104841240 #> v 1.289869216 -0.53099978 0.554917692 0.589941796 #> v -0.195721679 -1.19405934 0.459632538 -0.459338530 #> v -0.899990704 1.08230903 -0.965746126 0.302777458 #> v 0.703742539 -0.63163839 -0.199561212 0.254670972 #> v -0.183264272 0.60648638 0.347880587 -0.524957507 #> v 0.943690378 -0.39819295 -0.169208156 -0.512094803 #> v -1.293589351 -0.94159266 0.132036597 0.090742514 #> v 0.314309672 2.06075284 -0.208490942 0.251101305 #> v 0.701432015 0.49949524 -1.556766633 -0.717030388 #> v -1.198356249 -0.27001310 -0.386423880 0.078054486 #> v -1.220998921 -1.02454212 0.758212561 -1.011209592 #> v 1.022101553 -0.58317965 -0.424234236 -0.062818462 #> v -0.925970324 -0.74757997 0.101630133 0.001670814 #> v 0.617510775 -0.55673057 -0.043458426 0.269582351 #> v -0.516926118 1.07951484 -0.036623764 0.268163562 #> v 0.620836608 -0.88921477 0.694843768 -0.138892773 #> v -0.184672417 -0.48452681 0.368723585 0.754693096 #> v -0.958083274 0.57831178 0.072549096 -0.579174120 #> v -0.231967528 0.53222865 -0.991493275 -0.438457286 #> v -1.046542325 0.06217690 0.704410146 0.310598553 #> v -0.269670353 -0.76716734 -0.419653064 -0.169232653 #> v -0.885616206 1.34251504 -0.378237410 0.094117720 #> v -0.958890440 0.16000477 0.130098373 0.109070440 #> v 0.404221280 0.34183748 0.675495519 0.391750032 #> v 0.439211919 1.09838450 -0.143350043 0.270186266 #> v 0.626583272 -0.68059251 -0.121972993 0.273084337 #> v 0.094649172 -0.76382434 -0.002249440 0.257941875 #> v -0.608431351 -0.11739863 0.026283149 0.244986244 #> v -1.011050453 0.67359172 -0.245181145 -0.461270584 #> v -1.185176420 0.56019050 0.624204949 -0.283715633 #> v 0.814269086 -0.57517153 -0.996524796 0.220735917 #> v -0.452803527 1.59014881 0.122563909 0.034270473 #> v 0.375485811 -3.15302713 -0.064510552 -1.192408825 #> v 0.317279836 0.55126349 -0.497967778 -1.042117599 #> v 1.342978721 -1.11577475 -0.993502138 0.229845680 #> v -1.539680022 -0.51631147 0.101776992 0.178152732 #> v 0.150459929 0.98744537 0.131107977 0.066948893 #> v 0.264391044 -0.71078603 -0.031388824 -0.564815730 #> v 1.940846816 -1.67248484 0.025693693 0.882112123 #> v -1.596866233 -0.48562951 0.129017555 0.054828634 #> v 0.280850372 -2.20309572 -0.271172314 0.216249188 #> v -1.401575668 -0.69417967 -0.360451667 0.123724206 #> v -0.560658910 0.62573585 0.623761566 -0.284404282 #> v -1.232920895 1.35441566 0.296945767 -0.545503594 #> v -1.427083209 -2.67241211 0.326609341 -0.534179906 #> v -0.025033532 -0.44950296 0.158346888 0.852449840 #> v -0.241355264 -0.24089241 0.014070128 0.251087909 #> v -1.298684325 0.56470279 -1.034587356 -0.262219786 #> v -0.542723592 -0.65822242 -1.032416478 0.075526102 #> v 0.267792825 0.25748785 0.132178900 0.084106227 #> v 0.771398270 -1.34695778 1.356185294 -0.005949838 #> v 0.921291982 -1.29655349 0.050878741 0.229715967 #> v -1.097990465 -0.83534928 -0.965185345 -0.508563680 #> v -0.773771741 0.08223613 0.541280631 0.605930418 #> v 0.470530151 1.03004896 -0.985571868 -0.455589611 #> v 0.940065756 -0.32755551 0.368070054 -0.515311528 #> v 0.551310582 0.36406047 0.102463796 0.002557735 #> v -1.547159990 -0.04050991 1.186259901 0.769913128 #> v 0.082824660 -0.25576781 0.236384961 0.824241910 #> v 0.520073206 0.49584820 -0.630595803 -0.950911380 #> v 0.712867752 -1.05462256 0.131526445 0.098125000 #> v 0.420748799 -0.28634512 0.115636144 0.020339759 #> v -0.757125301 -1.51179154 -0.330983625 0.162204022 #> v -0.104191412 -0.27562351 0.494318248 1.394641819 #> v 1.706816143 0.63971207 -1.046511393 -0.060666648 #> v -0.195723760 1.11711298 0.475991181 0.672361606 #> v -1.052013551 -1.74165345 0.104671186 0.005019112 #> v -2.132953417 1.42979659 -0.653846423 -0.931869404 #> v 0.324042261 -0.54163968 0.131967284 0.092158456 #> v -1.475114463 0.73016662 -0.347277656 0.142250324 #> v 0.269536516 0.32955048 0.159799938 -0.576541014 #> v -0.198343327 2.04113580 0.131478091 0.070227111 #> v 0.927701662 0.05257081 -0.329524200 -0.374893986 #> v 1.125299520 -0.48753710 0.552679674 0.592624322 #> v -1.096061651 -0.20689643 -0.390401137 -1.098061198 #> v -1.870695786 -0.25126503 0.125550084 0.042267495 #> v 0.909689971 -1.06900433 -0.420318717 -0.165137296