On 23/10/2019 19:30, Andy Teucher wrote:
Hi Micha,

I can see two problems immediately with your code:
 1. you are using a double-colon (yr::last_yr) - the double colon is used for looking for an object in a package, so it is looking for object ‘yrs’ in package ‘yr’, which obviously doesn’t make sense. Use a single colon to create a range (like you did with 2:6) 2.  the object ‘last_yr’ is never defined, so even if you used a single colon to define the range yr:last_yr, it would fail as it would not be able to find object ‘last_yr’


Thanks,

I fixed those typos (corrected script attached) and I still get this error:


micha@tp480:R$ Rscript stars_window.R
Loading required package: abind
Loading required package: sf
Linking to GEOS 3.7.1, GDAL 2.4.0, PROJ 5.2.0
Error in eval(rlang::expr(x[[i]][!!!args])) : object 'yr' not found
Calls: RunMK -> [ -> [.stars -> structure -> eval -> eval
Execution halted



Cheers,
Andy Teucher

On Oct 23, 2019, at 8:28 AM, Micha Silver <tsvi...@gmail.com <mailto:tsvi...@gmail.com>> wrote:

I am trying to run a function (mk.test to find MannKendall trends) using st_apply over a "rolling" window for a time series of rasters in a stars object. When I use subscript notation to slice out the window dimension with a looping variable I get an error:

Error in loadNamespace(name) : there is no package called ‘yr’
Calls: [ ... tryCatch -> tryCatchList -> tryCatchOne -> <Anonymous>
Execution halted

However If I replace the subscript with integers it works fine. (see attached)
What is the correct way to work this out?

Attached is a reprex with a small subset of my data. (The script starts with a long structure, code is at the end)

Thanks
  --
Micha Silver
Ben Gurion Univ.
Sde Boker, Remote Sensing Lab
cell: +972-523-665918
<stars_window.R>_______________________________________________
R-sig-Geo mailing list
R-sig-Geo@r-project.org <mailto:R-sig-Geo@r-project.org>
https://stat.ethz.ch/mailman/listinfo/r-sig-geo

--
Micha Silver
Ben Gurion Univ.
Sde Boker, Remote Sensing Lab
cell: +972-523-665918

library(stars)
library(parallel)
library(trend)

ci_stars = structure(list(ci_by_years = structure(c(0.703296720981598, 0.708994686603546, 
0.704663217067719, 0.697435915470123, 0.676470577716827, 0.700507640838623, 
0.698412716388702, 0.726315796375275, 0.707070708274841, 0.705882370471954, 
0.713567852973938, 0.725388586521149, 0.732984304428101, 0.739583313465118, 
0.731958746910095, 0.717171728610992, 0.695652186870575, 0.701421797275543, 
0.69856458902359, 0.702970325946808, 0.686274528503418, 0.663636386394501, 
0.685185194015503, 0.672645747661591, 0.657534241676331, 0.672811031341553, 
0.651785731315613, 0.666666686534882, 0.709359586238861, 0.740000009536743, 
0.71875, 0.721649467945099, 0.728205144405365, 0.717948734760284, 
0.720812201499939, 0.709999978542328, 0.7156862616539, 0.696078419685364, 
0.696517407894135, 0.733668327331543, 0.666666686534882, 0.704225361347198, 
0.69856458902359, 0.685990333557129, 0.706467688083649, 0.730000019073486, 
0.69696968793869, 0.687830686569214, 0.693467319011688, 0.733668327331543, 
0.731958746910095, 0.701030910015106, 0.710659921169281, 0.709999978542328, 
0.728205144405365, 0.722772300243378, 0.7156862616539, 0.712871313095093, 
0.691099464893341, 0.714285731315613, 0.686274528503418, 0.710659921169281, 
0.724324345588684, 0.711111128330231, 0.72826087474823, 0.738461554050446, 
0.700507640838623, 0.713513493537903, 0.714285731315613, 0.731958746910095, 
0.724489808082581, 0.719576716423035, 0.717948734760284, 0.728205144405365, 
0.721649467945099, 0.711340188980103, 0.728205144405365, 0.734693884849548, 
0.709677398204803, 0.695652186870575, 0.686274528503418, 0.707070708274841, 
0.72251307964325, 0.687830686569214, 0.708333313465118, 0.693877577781677, 
0.707070708274841, 0.688172042369843, 0.695652186870575, 0.707692325115204, 
0.683417081832886, 0.708333313465118, 0.701570689678192, 0.715789496898651, 
0.695187151432037, 0.697435915470123, 0.701030910015106, 0.6875, 
0.687830686569214, 0.694300532341003, 0.716981112957001, 0.689320385456085, 
0.693467319011688, 0.69035530090332, 0.696517407894135, 0.69767439365387, 
0.675799071788788, 0.65437787771225, 0.64734297990799, 0.669856488704681, 
0.654205620288849, 0.679425835609436, 0.682926833629608, 0.676616907119751, 
0.697435915470123, 0.676616907119751, 0.638095259666443, 0.65727698802948, 
0.654545426368713, 0.62555068731308, 0.717703342437744, 0.69072163105011, 
0.715025901794434, 0.717948734760284, 0.693069279193878, 0.676470577716827, 
0.666666686534882, 0.700507640838623, 0.707692325115204, 0.69696968793869, 
0.65765768289566, 0.666666686534882, 0.646808505058289, 0.652542352676392, 
0.632034659385681, 0.639004170894623, 0.652173936367035, 0.672811031341553, 
0.675799071788788, 0.669767439365387, 0.703517615795135, 0.669950723648071, 
0.682926833629608, 0.685990333557129, 0.694835662841797, 0.693467319011688, 
0.717171728610992, 0.716417908668518, 0.704663217067719, 0.697435915470123, 
0.685714304447174, 0.679611623287201, 0.672985792160034, 0.678733050823212, 
0.633333325386047, 0.638655483722687, 0.672985792160034, 0.728205144405365, 
0.708333313465118, 0.711340188980103, 0.669767439365387, 0.666666686534882, 
0.685714304447174, 0.695652186870575, 0.709999978542328, 0.707692325115204, 
0.717948734760284, 0.711340188980103, 0.731958746910095, 0.689320385456085, 
0.679245293140411, 0.669856488704681, 0.649350643157959, 0.666666686534882, 
0.700460851192474, 0.685990333557129, 0.712195098400116, 0.732673287391663, 
0.707692325115204, 0.714285731315613, 0.685185194015503, 0.691588759422302, 
0.716417908668518, 0.720812201499939, 0.720812201499939, 0.72251307964325, 
0.719576716423035, 0.715025901794434, 0.693069279193878, 0.679245293140411, 
0.672727286815643, 0.644351482391357, 0.672489106655121, 0.691588759422302, 
0.71921181678772, 0.730964481830597, 0.741116762161255, 0.71921181678772, 
0.716417908668518, 0.722772300243378, 0.703030288219452, 0.697142839431763, 
0.666666686534882, 0.67441862821579, 0.682080924510956, 0.681818187236786, 
0.681818187236786, 0.688524603843689, 0.698924720287323, 0.677777767181396, 
0.707182347774506, 0.707182347774506, 0.707865178585052, 0.708571434020996, 
0.697142839431763, 0.723163843154907, 0.703296720981598, 0.701030910015106, 
0.683937847614288, 0.688888907432556, 0.680628299713135, 0.69072163105011, 
0.68085104227066, 0.676767647266388, 0.676767647266388, 0.694300532341003, 
0.65625, 0.685082852840424, 0.697142839431763, 0.689655184745789, 
0.711111128330231, 0.69945353269577, 0.695652186870575, 0.703296720981598, 
0.700564980506897, 0.693181812763214, 0.715909063816071, 0.734463274478912, 
0.711111128330231, 0.729281783103943, 0.683937847614288, 0.713513493537903, 
0.721311450004578, 0.707865178585052, 0.686390519142151, 0.694117665290833, 
0.690909087657928, 0.6875, 0.695652186870575, 0.721893489360809, 
0.727272748947144, 0.718232035636902, 0.69945353269577, 0.703296720981598, 
0.693641602993011, 0.686390519142151, 0.708571434020996, 0.719101130962372, 
0.720000028610229, 0.734463274478912, 0.70114940404892, 0.703030288219452, 
0.721893489360809, 0.71856290102005, 0.695121943950653, 0.695652186870575, 
0.717948734760284, 0.710526287555695, 0.701298713684082, 0.716049373149872, 
0.723926365375519, 0.714285731315613, 0.728323698043823, 0.717647075653076, 
0.68711656332016, 0.695121943950653, 0.715151488780975, 0.721893489360809, 
0.705882370471954, 0.705882370471954, 0.681318700313568, 0.685714304447174, 
0.690476179122925, 0.678571403026581, 0.681818187236786, 0.691489338874817, 
0.681564271450043, 0.686046540737152, 0.690909087657928, 0.706586837768555, 
0.692737400531769, 0.70175439119339, 0.682634711265564, 0.698795199394226, 
0.682926833629608, 0.690476179122925, 0.689655184745789, 0.674157321453094, 
0.689655184745789, 0.645502626895905, 0.691099464893341, 0.697916686534882, 
0.68085104227066, 0.670212745666504, 0.69189190864563, 0.696132600307465, 
0.69189190864563, 0.692307710647583, 0.699999988079071, 0.68478262424469, 
0.670103073120117, 0.666666686534882, 0.673469364643097, 0.660000026226044, 
0.649484515190125, 0.670050740242004, 0.646766185760498, 0.650246322154999, 
0.637254893779755, 0.641148328781128, 0.695652186870575, 0.677777767181396, 
0.718232035636902, 0.674157321453094, 0.666666686534882, 0.666666686534882, 
0.677966117858887, 0.685714304447174, 0.70114940404892, 0.666666686534882, 
0.673684239387512, 0.676767647266388, 0.666666686534882, 0.653846144676208, 
0.647619068622589, 0.660714268684387, 0.641509413719177, 0.656084656715393, 
0.687830686569214, 0.698412716388702, 0.681081056594849, 0.677595615386963, 
0.681081056594849, 0.694736838340759, 0.705882370471954, 0.692307710647583, 
0.681818187236786, 0.670454561710358, 0.689655184745789, 0.681564271450043, 
0.677595615386963, 0.681564271450043, 0.670270264148712, 0.669950723648071, 
0.660194158554077, 0.663461565971375, 0.673684239387512, 0.70391058921814, 
0.692737400531769, 0.681818187236786, 0.673366844654083, 0.680000007152557, 
0.687179505825043, 0.687830686569214, 0.656084656715393, 0.677419364452362, 
0.698924720287323, 0.692307710647583, 0.692737400531769, 0.685082852840424, 
0.68478262424469, 0.649746179580688, 0.666666686534882, 0.656410276889801, 
0.670329689979553, 0.692307710647583, 0.68085104227066, 0.659340679645538, 
0.714285731315613, 0.707865178585052, 0.686567187309265, 0.69035530090332, 
0.687830686569214, 0.695652186870575, 0.703296720981598, 0.685082852840424, 
0.710382521152496, 0.69945353269577, 0.698924720287323, 0.688524603843689, 
0.683937847614288, 0.645833313465118, 0.666666686534882, 0.630303025245667, 
0.670807480812073, 0.699999988079071, 0.729411780834198, 0.684491991996765, 
0.701030910015106, 0.696132600307465, 0.670658707618713, 0.662921369075775, 
0.677777767181396, 0.666666686534882, 0.645502626895905, 0.639593899250031, 
0.646766185760498, 0.653266310691833, 0.677248656749725, 0.673913061618805, 
0.684491991996765, 0.688888907432556, 0.722222208976746, 0.707865178585052, 
0.689265549182892, 0.677595615386963, 0.680628299713135, 0.686868667602539, 
0.693877577781677, 0.677595615386963, 0.666666686534882, 0.660194158554077, 
0.663366317749023, 0.647887349128723, 0.638497650623322, 0.650246322154999, 
0.646766185760498, 0.65263158082962, 0.674285709857941, 0.685714304447174, 
0.699999988079071, 0.666666686534882, 0.69189190864563, 0.692307710647583, 
0.700564980506897, 0.681564271450043, 0.697142839431763, 0.693181812763214, 
0.696629226207733, 0.697142839431763, 0.670103073120117, 0.68478262424469, 
0.696629226207733, 0.696629226207733, 0.690058469772339, 0.70175439119339, 
0.683544278144836, 0.671328663825989, 0.684563755989075, 0.699999988079071, 
0.717647075653076, 0.696132600307465, 0.681081056594849, 0.70391058921814, 
0.71005916595459, 0.686390519142151, 0.7108433842659, 0.69822484254837, 
0.69767439365387, 0.678787887096405, 0.662857115268707, 0.683229804039001, 
0.691823899745941, 0.695121943950653, 0.698795199394226, 0.722891569137573, 
0.697986602783203, 0.705882370471954, 0.705035984516144, 0.679738581180573, 
0.709677398204803, 0.707317054271698, 0.693641602993011, 0.698795199394226, 
0.686747014522552, 0.682926833629608, 0.691358029842377, 0.691358029842377, 
0.691823899745941, 0.682926833629608, 0.684491991996765, 0.662983417510986, 
0.674285709857941, 0.689655184745789, 0.641711235046387, 0.663366317749023, 
0.652406394481659, 0.681818187236786, 0.658682644367218, 0.643678188323975, 
0.644808769226074, 0.651428580284119, 0.662790715694427, 0.670454561710358, 
0.6589595079422, 0.670454561710358, 0.670212745666504, 0.645502626895905, 
0.656084656715393, 0.631067931652069, 0.666666686534882, 0.659793794155121, 
0.673575103282928, 0.659793794155121, 0.66304349899292, 0.673575103282928, 
0.680203020572662, 0.670103073120117, 0.659459471702576, 0.652849733829498, 
0.638888895511627, 0.633027493953705, 0.606334865093231, 0.622222244739532, 
0.620370388031006, 0.636363625526428, 0.637168169021606, 0.628318607807159, 
0.626086950302124, 0.638297855854034, 0.680628299713135, 0.677777767181396, 
0.689265549182892, 0.65193372964859, 0.677248656749725, 0.683937847614288, 
0.688172042369843, 0.696132600307465, 0.678160905838013, 0.662790715694427, 
0.660194158554077, 0.632558166980743, 0.623853206634521, 0.633928596973419, 
0.624472558498383, 0.62650603055954, 0.649122834205627, 0.666666686534882, 
0.670270264148712, 0.698924720287323, 0.677248656749725, 0.663157880306244, 
0.659793794155121, 0.64039409160614, 0.673366844654083, 0.69945353269577, 
0.69945353269577, 0.703296720981598, 0.696629226207733, 0.677595615386963, 
0.683673441410065, 0.666666686534882, 0.643216073513031, 0.642201840877533, 
0.642533957958221, 0.657534241676331, 0.68085104227066, 0.716763019561768, 
0.705202341079712, 0.697142839431763, 0.650485455989838, 0.653658509254456, 
0.666666686534882, 0.663265287876129, 0.670000016689301, 0.680628299713135, 
0.694736838340759, 0.695187151432037, 0.68478262424469, 0.666666686534882, 
0.656716406345367, 0.636363625526428, 0.62555068731308, 0.638743460178375, 
0.678160905838013, 0.682080924510956, 0.670329689979553, 0.674157321453094, 
0.689655184745789, 0.70175439119339, 0.660194158554077, 0.673469364643097, 
0.688172042369843, 0.692307710647583, 0.677966117858887, 0.681564271450043, 
0.695652186870575, 0.688172042369843, 0.677248656749725, 0.659793794155121, 
0.663414657115936, 0.628019332885742, 0.671052634716034, 0.676258981227875, 
0.699999988079071, 0.715328454971313, 0.697368443012238, 0.688172042369843, 
0.705263137817383, 0.685082852840424, 0.698795199394226, 0.697142839431763, 
0.70114940404892, 0.670391082763672, 0.655367255210876, 0.681564271450043, 
0.659459471702576, 0.666666686534882, 0.670050740242004, 0.676923096179962, 
0.670157074928284, 0.689265549182892, 0.697142839431763, 0.693181812763214, 
0.692737400531769, 0.698924720287323, 0.703517615795135, 0.692307710647583, 
0.660194158554077, 0.670157074928284, 0.663366317749023, 0.672985792160034, 
0.672985792160034, 0.663636386394501, 0.651583731174469, 0.663551390171051, 
0.636363625526428, 0.673267304897308, 0.684210538864136, 0.705263137817383, 
0.695652186870575, 0.688524603843689, 0.703296720981598, 0.714285731315613, 
0.700564980506897, 0.688524603843689, 0.702702701091766, 0.695652186870575, 
0.688888907432556, 0.696629226207733, 0.672985792160034, 0.689999997615814, 
0.69696968793869, 0.712041914463043, 0.711864411830902, 0.681564271450043, 
0.696132600307465, 0.68711656332016, 0.682634711265564, 0.70114940404892, 
0.704545438289642, 0.711111128330231, 0.702702701091766, 0.714285731315613, 
0.700564980506897, 0.708571434020996, 0.696629226207733, 0.685714304447174, 
0.689265549182892, 0.689655184745789, 0.694736838340759, 0.724137902259827, 
0.726190447807312, 0.714285731315613, 0.690909087657928, 0.699386477470398, 
0.699999988079071, 0.693877577781677, 0.701298713684082, 0.682926833629608, 
0.704402506351471, 0.698795199394226, 0.689655184745789, 0.71005916595459, 
0.705882370471954, 0.71856290102005, 0.694117665290833, 0.706586837768555, 
0.703703701496124, 0.68711656332016, 0.684210538864136, 0.711111128330231, 
0.71005916595459, 0.714285731315613, 0.670391082763672, 0.670157074928284, 
0.68085104227066, 0.674285709857941, 0.6875, 0.712499976158142, 
0.681564271450043, 0.686046540737152, 0.706586837768555, 0.694117665290833, 
0.69767439365387, 0.693641602993011, 0.677595615386963, 0.688888907432556, 
0.66304349899292, 0.646464645862579, 0.686567187309265, 0.689999997615814, 
0.659898459911346, 0.670050740242004, 0.680628299713135, 0.670103073120117, 
0.657142877578735, 0.669950723648071, 0.670157074928284, 0.663265287876129, 
0.641148328781128, 0.622009575366974, 0.622009575366974, 0.644230782985687, 
0.650485455989838, 0.663461565971375, 0.6355140209198, 0.646017670631409, 
0.641975283622742, 0.62601625919342, 0.717171728610992, 0.687830686569214, 
0.703296720981598, 0.711111128330231, 0.687830686569214, 0.683673441410065, 
0.676767647266388, 0.69072163105011, 0.696629226207733, 0.681318700313568, 
0.666666686534882, 0.646017670631409, 0.643478274345398, 0.643478274345398, 
0.62184876203537, 0.631578922271729, 0.631147563457489, 0.663507103919983, 
0.669950723648071, 0.663366317749023, 0.701570689678192, 0.691489338874817, 
0.69072163105011, 0.699507415294647, 0.69696968793869, 0.695187151432037, 
0.701570689678192, 0.698924720287323, 0.718232035636902, 0.673684239387512, 
0.689655184745789, 0.686868667602539, 0.657004833221436, 0.654867231845856, 
0.638655483722687, 0.638655483722687, 0.683168292045593, 0.693641602993011, 
0.689655184745789, 0.685082852840424, 0.676470577716827, 0.691943109035492, 
0.700934588909149, 0.705882370471954, 0.673366844654083, 0.687830686569214, 
0.702127635478973, 0.684491991996765, 0.719576716423035, 0.673366844654083, 
0.666666686534882, 0.666666686534882, 0.643478274345398, 0.663594484329224, 
0.689655184745789, 0.67980295419693, 0.679611623287201, 0.701570689678192, 
0.692737400531769, 0.677595615386963, 0.673076927661896, 0.706467688083649, 
0.719576716423035, 0.707182347774506, 0.703296720981598, 0.711111128330231, 
0.736263751983643, 0.69189190864563, 0.67980295419693, 0.694063901901245, 
0.632911384105682, 0.652542352676392, 0.680000007152557, 0.709677398204803, 
0.713450312614441, 0.7108433842659, 0.714285731315613, 0.708994686603546, 
0.676923096179962, 0.684491991996765, 0.666666686534882, 0.666666686534882, 
0.649746179580688, 0.635416686534882, 0.626262605190277, 0.639593899250031, 
0.64039409160614, 0.651162803173065, 0.644549787044525, 0.64390242099762, 
0.649999976158142, 0.670103073120117, 0.670157074928284, 0.680412352085114, 
0.676767647266388, 0.659898459911346, 0.660194158554077, 0.654205620288849, 
0.672897219657898, 0.673267304897308, 0.638095259666443, 0.645739912986755, 
0.645739912986755, 0.655172407627106, 0.630705416202545, 0.644067823886871, 
0.610878646373749, 0.642857134342194, 0.663316607475281, 0.676616907119751, 
0.673469364643097, 0.676767647266388, 0.649746179580688, 0.680203020572662, 
0.663212418556213, 0.673469364643097, 0.683673441410065, 0.683673441410065, 
0.666666686534882, 0.673684239387512, 0.639269411563873, 0.660377383232117, 
0.67980295419693, 0.696078419685364, 0.694736838340759, 0.68085104227066, 
0.677083313465118, 0.685082852840424, 0.674033164978027, 0.663101613521576, 
0.695187151432037, 0.691099464893341, 0.69072163105011, 0.69035530090332, 
0.684210538864136, 0.691489338874817, 0.655737698078156, 0.691489338874817, 
0.677419364452362, 0.691489338874817, 0.659898459911346, 0.670270264148712, 
0.674285709857941, 0.685393273830414, 0.677419364452362, 0.677419364452362, 
0.685082852840424, 0.703030288219452, 0.682926833629608, 0.654970765113831, 
0.670454561710358, 0.688888907432556, 0.705882370471954, 0.666666686534882, 
0.659217894077301, 0.685714304447174, 0.677966117858887, 0.685393273830414, 
0.693641602993011, 0.651428580284119, 0.669902920722961, 0.63589745759964, 
0.648648619651794, 0.666666686534882, 0.686868667602539, 0.64734297990799, 
0.640776693820953, 0.656084656715393, 0.662921369075775, 0.662983417510986, 
0.63589745759964, 0.634408593177795, 0.644444465637207, 0.659217894077301, 
0.644808769226074, 0.666666686534882, 0.663157880306244, 0.632124364376068, 
0.635416686534882, 0.64390242099762, 0.654205620288849, 0.650717675685883, 
0.650717675685883, 0.65437787771225, 0.641509413719177, 0.663551390171051, 
0.645739912986755, 0.639269411563873, 0.657004833221436, 0.650485455989838, 
0.614678919315338, 0.611872136592865, 0.629629611968994, 0.635071098804474, 
0.638497650623322, 0.639269411563873, 0.628318607807159, 0.646288216114044, 
0.622950792312622, 0.625, 0.676190495491028, 0.666666686534882, 
0.666666686534882, 0.683937847614288, 0.639999985694885, 0.64734297990799, 
0.666666686534882, 0.663461565971375, 0.660000026226044, 0.653266310691833, 
0.645739912986755, 0.619834721088409, 0.629482090473175, 0.639999985694885, 
0.615384638309479, 0.620155036449432, 0.632411062717438, 0.642857134342194, 
0.641860485076904, 0.672727286815643, 0.660000026226044, 0.656862735748291, 
0.654028415679932, 0.660465121269226, 0.654205620288849, 0.686274528503418, 
0.660098493099213, 0.656862735748291, 0.670050740242004, 0.653061211109161, 
0.660377383232117, 0.650485455989838, 0.64390242099762, 0.64069265127182, 
0.62650603055954, 0.613545835018158, 0.634361207485199, 0.683937847614288, 
0.6875, 0.697435915470123, 0.639639616012573, 0.628318607807159, 
0.651376128196716, 0.666666686534882, 0.666666686534882, 0.686274528503418, 
0.663366317749023, 0.676767647266388, 0.669950723648071, 0.650717675685883, 
0.636363625526428, 0.621276617050171, 0.634920656681061, 0.617391288280487, 
0.660550475120544, 0.663551390171051, 0.666666686534882, 0.683168292045593, 
0.689999997615814, 0.666666686534882, 0.672645747661591, 0.654205620288849, 
0.673366844654083, 0.686868667602539, 0.700507640838623, 0.666666686534882, 
0.680203020572662, 0.676767647266388, 0.657004833221436, 0.639999985694885, 
0.650602400302887, 0.626984119415283, 0.638497650623322, 0.647619068622589, 
0.670157074928284, 0.695187151432037, 0.684491991996765, 0.65656566619873, 
0.657142877578735, 0.6822429895401, 0.657894730567932, 0.678787887096405, 
0.654088079929352, 0.670588254928589, 0.655555546283722, 0.634408593177795, 
0.634408593177795, 0.647727251052856, 0.666666686534882, 0.670454561710358, 
0.686046540737152, 0.69822484254837, 0.694610774517059, 0.674698770046234, 
0.666666686534882, 0.6705202460289, 0.666666686534882, 0.681318700313568, 
0.659090936183929, 0.689655184745789, 0.659217894077301, 0.642487049102783, 
0.649214684963226, 0.653266310691833, 0.659793794155121, 0.673796772956848, 
0.643216073513031, 0.652173936367035, 0.650887548923492, 0.682634711265564, 
0.666666686534882, 0.674698770046234, 0.686390519142151, 0.70175439119339, 
0.678787887096405, 0.679012358188629, 0.698795199394226, 0.690058469772339, 
0.682352960109711, 0.678787887096405, 0.677419364452362, 0.692737400531769, 
0.69822484254837, 0.683544278144836, 0.679012358188629, 0.691358029842377, 
0.670886099338531, 0.702702701091766, 0.701298713684082, 0.711409389972687, 
0.675159215927124, 0.682926833629608, 0.662650585174561, 0.678571403026581, 
0.679012358188629, 0.700636923313141, 0.703703701496124, 0.695652186870575, 
0.687898099422455, 0.687898099422455, 0.698795199394226, 0.703448295593262, 
0.689655184745789, 0.721088409423828, 0.716216206550598, 0.716216206550598, 
0.695035457611084, 0.69767439365387, 0.671428561210632, 0.688741743564606, 
0.688741743564606, 0.688311696052551, 0.696202516555786, 0.662251651287079, 
0.684210538864136, 0.703448295593262, 0.692810475826263, 0.718954265117645, 
0.710526287555695, 0.675496697425842, 0.678362548351288, 0.662420392036438, 
0.679738581180573, 0.670731723308563, 0.677966117858887, 0.666666686534882, 
0.670731723308563, 0.670967757701874, 0.675862073898315, 0.657342672348022, 
0.666666686534882, 0.639999985694885, 0.662251651287079, 0.671052634716034, 
0.679245293140411, 0.674698770046234, 0.678571403026581, 0.670588254928589, 
0.645161271095276, 0.629999995231628, 0.677419364452362, 0.670270264148712, 
0.677595615386963, 0.681318700313568, 0.677966117858887, 0.662983417510986, 
0.655913949012756, 0.65193372964859, 0.666666686534882, 0.673366844654083, 
0.633663356304169, 0.628865957260132, 0.63589745759964, 0.64615386724472, 
0.649214684963226, 0.65656566619873, 0.624434411525726, 0.637554585933685, 
0.637168169021606, 0.649122834205627, 0.674157321453094, 0.690909087657928, 
0.69822484254837, 0.666666686534882, 0.677777767181396, 0.666666686534882, 
0.662921369075775, 0.694117665290833, 0.700636923313141, 0.662650585174561, 
0.639175236225128, 0.650485455989838, 0.628019332885742, 0.639639616012573, 
0.627118647098541, 0.632411062717438, 0.646808505058289, 0.645502626895905, 
0.666666686534882, 0.677248656749725, 0.666666686534882, 0.647058844566345, 
0.648351669311523, 0.673575103282928, 0.688524603843689, 0.685714304447174, 
0.662721872329712, 0.693641602993011, 0.654970765113831, 0.659217894077301, 
0.659340679645538, 0.648936152458191, 0.643564343452454, 0.644549787044525, 
0.624434411525726, 0.626728117465973, 0.659217894077301, 0.695652186870575, 
0.674846649169922, 0.670731723308563, 0.670050740242004, 0.649999976158142, 
0.673684239387512, 0.677419364452362, 0.685082852840424, 0.681818187236786, 
0.670454561710358, 0.681564271450043, 0.636363625526428, 0.673684239387512, 
0.650246322154999, 0.629629611968994, 0.638497650623322, 0.669950723648071, 
0.663101613521576, 0.684210538864136, 0.666666686534882, 0.6589595079422, 
0.678787887096405, 0.670588254928589, 0.659898459911346, 0.681081056594849, 
0.67441862821579, 0.682634711265564, 0.714285731315613, 0.68711656332016, 
0.693641602993011, 0.681564271450043, 0.681081056594849, 0.65625, 
0.6355140209198, 0.638095259666443, 0.648351669311523, 0.674698770046234, 
0.68711656332016, 0.714285731315613, 0.6875, 0.674157321453094, 
0.666666686534882, 0.681818187236786, 0.663101613521576, 0.680203020572662, 
0.686567187309265, 0.666666686534882, 0.647058844566345, 0.657004833221436, 
0.637681186199188, 0.651162803173065, 0.657142877578735, 0.670000016689301, 
0.673366844654083, 0.69035530090332, 0.693877577781677, 0.693467319011688, 
0.680203020572662, 0.676767647266388, 0.67980295419693, 0.679245293140411, 
0.679245293140411, 0.686274528503418, 0.65437787771225, 0.672811031341553, 
0.666666686534882, 0.651583731174469, 0.637554585933685, 0.620689630508423, 
0.622807025909424, 0.660287082195282, 0.6875, 0.694300532341003, 
0.687179505825043, 0.673469364643097, 0.69072163105011, 0.683673441410065, 
0.693877577781677, 0.683673441410065, 0.69696968793869, 0.683417081832886, 
0.683673441410065, 0.677083313465118, 0.672985792160034, 0.703517615795135, 
0.677083313465118, 0.666666686534882, 0.695652186870575, 0.684210538864136, 
0.688172042369843, 0.688888907432556, 0.677419364452362, 0.705882370471954, 
0.688172042369843, 0.68085104227066, 0.680412352085114, 0.683417081832886, 
0.6875, 0.705882370471954, 0.698412716388702, 0.680412352085114, 
0.68085104227066, 0.680628299713135, 0.677419364452362, 0.70114940404892, 
0.694610774517059, 0.678160905838013, 0.677595615386963, 0.670329689979553, 
0.67441862821579, 0.695652186870575, 0.682634711265564, 0.681564271450043, 
0.696629226207733, 0.695652186870575, 0.69189190864563, 0.702702701091766, 
0.674157321453094, 0.700564980506897, 0.688888907432556, 0.681564271450043, 
0.662790715694427, 0.70652174949646, 0.686567187309265, 0.65263158082962, 
0.66304349899292, 0.652406394481659, 0.663212418556213, 0.653465330600739, 
0.670103073120117, 0.677595615386963, 0.666666686534882, 0.656410276889801, 
0.666666686534882, 0.670329689979553, 0.685082852840424, 0.673913061618805, 
0.65193372964859, 0.666666686534882, 0.666666686534882, 0.64615386724472, 
0.629441618919373, 0.622009575366974, 0.700934588909149, 0.663366317749023, 
0.666666686534882, 0.660194158554077, 0.653061211109161, 0.656862735748291, 
0.669811308383942, 0.64039409160614, 0.65625, 0.660194158554077, 
0.642533957958221, 0.6355140209198, 0.647619068622589, 0.650943398475647, 
0.651162803173065, 0.631111085414886, 0.626609444618225, 0.630252122879028, 
0.609756112098694, 0.636734664440155, 0.680203020572662, 0.6875, 
0.670103073120117, 0.680203020572662, 0.656716406345367, 0.660098493099213, 
0.660000026226044, 0.686868667602539, 0.677083313465118, 0.669950723648071, 
0.654867231845856, 0.646551728248596, 0.627118647098541, 0.627615034580231, 
0.634538173675537, 0.621513962745667, 0.635193109512329, 0.651162803173065, 
0.647058844566345, 0.676616907119751, 0.669950723648071, 0.666666686534882, 
0.676190495491028, 0.67592591047287, 0.660287082195282, 0.693877577781677, 
0.680000007152557, 0.676923096179962, 0.683937847614288, 0.653061211109161, 
0.669811308383942, 0.653061211109161, 0.644549787044525, 0.64069265127182, 
0.633744835853577, 0.632478654384613, 0.666666686534882, 0.68085104227066, 
0.687830686569214, 0.691489338874817, 0.645739912986755, 0.672811031341553, 
0.685714304447174, 0.676470577716827, 0.676616907119751, 0.686868667602539, 
0.693877577781677, 0.69035530090332, 0.669950723648071, 0.660377383232117, 
0.627802670001984, 0.630252122879028, 0.636363625526428, 0.648148119449615, 
0.669811308383942, 0.672985792160034, 0.689655184745789, 0.686868667602539, 
0.673575103282928, 0.673469364643097, 0.647887349128723, 0.673170745372772, 
0.687179505825043, 0.701030910015106, 0.6875, 0.68085104227066, 
0.701030910015106, 0.683168292045593, 0.669811308383942, 0.652173936367035, 
0.647540986537933, 0.618025779724121, 0.638743460178375, 0.684210538864136, 
0.694300532341003, 0.705882370471954, 0.68085104227066, 0.682926833629608, 
0.686274528503418, 0.680203020572662, 0.64327484369278, 0.662790715694427, 
0.64327484369278, 0.639999985694885, 0.632768332958221, 0.659340679645538, 
0.670329689979553, 0.656084656715393, 0.666666686534882, 0.659685850143433, 
0.673684239387512, 0.663157880306244, 0.659793794155121, 0.680412352085114, 
0.683937847614288, 0.670212745666504, 0.659685850143433, 0.666666686534882, 
0.657004833221436, 0.677083313465118, 0.632653057575226, 0.647058844566345, 
0.653465330600739, 0.638497650623322, 0.631578922271729, 0.629310369491577, 
0.634361207485199, 0.657004833221436, 0.662983417510986, 0.680628299713135, 
0.691489338874817, 0.652406394481659, 0.683673441410065, 0.670157074928284, 
0.663157880306244, 0.677248656749725, 0.69189190864563, 0.677248656749725, 
0.673796772956848, 0.677595615386963, 0.657004833221436, 0.676616907119751, 
0.6875, 0.684210538864136, 0.666666686534882, 0.64804470539093, 
0.674157321453094, 0.678160905838013, 0.647058844566345, 0.674157321453094, 
0.685714304447174, 0.659340679645538, 0.707692325115204, 0.666666686534882, 
0.666666686534882, 0.685082852840424, 0.696629226207733, 0.673913061618805, 
0.677777767181396, 0.689265549182892, 0.666666686534882, 0.686747014522552, 
0.699999988079071, 0.690476179122925, 0.670454561710358, 0.670454561710358, 
0.675000011920929, 0.666666686534882, 0.657894730567932, 0.645962715148926, 
0.670731723308563, 0.658823549747467, 0.688888907432556, 0.67441862821579, 
0.670658707618713, 0.674698770046234, 0.674698770046234, 0.690058469772339, 
0.68711656332016, 0.662650585174561, 0.656084656715393, 0.654970765113831, 
0.662500023841858, 0.646341443061829, 0.6589595079422, 0.652406394481659, 
0.666666686534882, 0.645962715148926, 0.649681508541107, 0.63095235824585, 
0.640449464321136, 0.662790715694427, 0.641509413719177, 0.662500023841858, 
0.654761910438538, 0.651428580284119, 0.643678188323975, 0.659217894077301, 
0.639999985694885, 0.645502626895905, 0.670000016689301, 0.65656566619873, 
0.64615386724472, 0.643564343452454, 0.64615386724472, 0.645502626895905, 
0.642487049102783, 0.652849733829498, 0.645161271095276, 0.635416686534882, 
0.631067931652069, 0.626262605190277, 0.620320856571198, 0.633879780769348, 
0.634920656681061, 0.634615361690521, 0.628571450710297, 0.630136966705322, 
0.610169470310211, 0.605809152126312, 0.656410276889801, 0.66304349899292, 
0.655913949012756, 0.659459471702576, 0.666666686534882, 0.663212418556213, 
0.653061211109161, 0.652849733829498, 0.670212745666504, 0.659685850143433, 
0.641509413719177, 0.637168169021606, 0.627118647098541, 0.635193109512329, 
0.60262006521225, 0.605809152126312, 0.62184876203537, 0.639639616012573, 
0.657407402992249, 0.660377383232117, 0.652406394481659, 0.655737698078156, 
0.659685850143433, 0.649999976158142, 0.660000026226044, 0.663212418556213, 
0.652406394481659, 0.673796772956848, 0.688172042369843, 0.652173936367035, 
0.646464645862579, 0.673469364643097, 0.666666686534882, 0.638888895511627, 
0.616666674613953, 0.622950792312622, 0.657407402992249, 0.673684239387512, 
0.677595615386963, 0.681081056594849, 0.660377383232117, 0.663507103919983, 
0.663414657115936, 0.673170745372772, 0.670000016689301, 0.663265287876129, 
0.676923096179962, 0.683937847614288, 0.670157074928284, 0.666666686534882, 
0.64615386724472, 0.61904764175415, 0.646551728248596, 0.642857134342194, 
0.641509413719177, 0.647619068622589, 0.656862735748291, 0.673575103282928, 
0.670212745666504, 0.656084656715393, 0.666666686534882, 0.676328480243683, 
0.673575103282928, 0.684210538864136, 0.694736838340759, 0.695652186870575, 
0.670212745666504, 0.666666686534882, 0.645833313465118, 0.644230782985687, 
0.611872136592865, 0.632911384105682, 0.637681186199188, 0.660000026226044, 
0.680412352085114, 0.659459471702576, 0.656084656715393, 0.653266310691833, 
0.646766185760498, 0.65625, 0.663265287876129, 0.623762369155884, 
0.660287082195282, 0.644549787044525, 0.636363625526428, 0.629629611968994, 
0.616113722324371, 0.639269411563873, 0.638497650623322, 0.685714304447174, 
0.676328480243683, 0.653658509254456, 0.672985792160034, 0.663507103919983, 
0.669856488704681, 0.676328480243683, 0.666666686534882, 0.666666686534882, 
0.666666686534882, 0.660194158554077, 0.654545426368713, 0.637168169021606, 
0.657777786254883, 0.646288216114044, 0.635983288288116, 0.638297855854034, 
0.633333325386047, 0.64069265127182, 0.673076927661896, 0.699029147624969, 
0.689999997615814, 0.673170745372772, 0.660194158554077, 0.666666686534882, 
0.676190495491028, 0.688372075557709, 0.673170745372772, 0.676328480243683, 
0.673076927661896, 0.669902920722961, 0.657777786254883, 0.660465121269226, 
0.673076927661896, 0.689320385456085, 0.676616907119751, 0.686868667602539, 
0.686567187309265, 0.676616907119751, 0.663414657115936, 0.660098493099213, 
0.6875, 0.680000007152557, 0.689655184745789, 0.685990333557129, 
0.656862735748291, 0.692682921886444, 0.693467319011688, 0.666666686534882, 
0.659898459911346, 0.676616907119751, 0.669856488704681, 0.683673441410065, 
0.69189190864563, 0.670270264148712, 0.652849733829498, 0.64615386724472, 
0.670157074928284, 0.688172042369843, 0.670270264148712, 0.659793794155121, 
0.670157074928284, 0.681081056594849, 0.680203020572662, 0.683417081832886, 
0.687179505825043, 0.704663217067719, 0.670270264148712, 0.677419364452362, 
0.677777767181396, 0.666666686534882, 0.660377383232117, 0.653658509254456, 
0.663212418556213, 0.670050740242004, 0.673366844654083, 0.644859790802002, 
0.654205620288849, 0.653465330600739, 0.652849733829498, 0.650246322154999, 
0.632558166980743, 0.653465330600739, 0.677419364452362, 0.685082852840424, 
0.663265287876129, 0.669950723648071, 0.623115599155426, 0.64390242099762, 
0.650246322154999, 0.639269411563873, 0.675675690174103, 0.666666686534882, 
0.663461565971375, 0.663594484329224, 0.65727698802948, 0.669767439365387, 
0.663636386394501, 0.654545426368713, 0.647619068622589, 0.641860485076904, 
0.614718616008759, 0.60526317358017, 0.616740107536316, 0.639999985694885, 
0.645161271095276, 0.631578922271729, 0.62978720664978, 0.623376607894897, 
0.634538173675537, 0.594377517700195, 0.666666686534882, 0.683168292045593, 
0.673267304897308, 0.663316607475281, 0.640776693820953, 0.65727698802948, 
0.64840179681778, 0.641148328781128, 0.666666686534882, 0.666666686534882, 
0.639999985694885, 0.638655483722687, 0.6147540807724, 0.597510397434235, 
0.611570239067078, 0.61904764175415, 0.637096762657166, 0.642857134342194, 
0.644859790802002, 0.653846144676208, 0.65727698802948, 0.672897219657898, 
0.65727698802948, 0.632558166980743, 0.657534241676331, 0.676328480243683, 
0.647619068622589, 0.657004833221436, 0.669902920722961, 0.669902920722961, 
0.654708504676819, 0.644549787044525, 0.642201840877533, 0.643776834011078, 
0.623481810092926, 0.62650603055954, 0.637168169021606, 0.660000026226044, 
0.686868667602539, 0.683168292045593, 0.643478274345398, 0.652173936367035, 
0.663636386394501, 0.654205620288849, 0.657142877578735, 0.656862735748291, 
0.660194158554077, 0.676470577716827, 0.660287082195282, 0.651376128196716, 
0.637931048870087, 0.628099203109741, 0.648648619651794, 0.652719676494598, 
0.648888885974884, 0.654708504676819, 0.651583731174469, 0.669811308383942, 
0.676328480243683, 0.669811308383942, 0.660792946815491, 0.672811031341553, 
0.676470577716827, 0.669950723648071, 0.676470577716827, 0.670050740242004, 
0.680203020572662, 0.679611623287201, 0.654205620288849, 0.646551728248596, 
0.64257025718689, 0.619403004646301, 0.655172407627106, 0.660869538784027, 
0.672897219657898, 0.669950723648071, 0.660098493099213, 0.654205620288849, 
0.660465121269226, 0.644230782985687, 0.681415915489197, 0.649572670459747, 
0.635983288288116, 0.638655483722687, 0.64462810754776, 0.61924684047699, 
0.644351482391357, 0.647773265838623, 0.655737698078156, 0.677824258804321, 
0.681034505367279, 0.669603526592255, 0.672489106655121, 0.686695277690887, 
0.686695277690887, 0.675000011920929, 0.669354856014252, 0.658634543418884, 
0.663967609405518, 0.658008635044098, 0.641975283622742, 0.634920656681061, 
0.627451002597809, 0.639999985694885, 0.637795269489288, 0.643137276172638, 
0.616600811481476, 0.640625, 0.658436238765717, 0.686695277690887, 
0.702222228050232, 0.699115037918091, 0.690265476703644, 0.678260862827301, 
0.683760702610016, 0.680497944355011, 0.672199189662933, 0.675105512142181, 
0.666666686534882, 0.672645747661591, 0.648221373558044, 0.658634543418884, 
0.663865566253662, 0.657894730567932, 0.690265476703644, 0.68122273683548, 
0.663865566253662, 0.675000011920929, 0.672268927097321, 0.66945606470108, 
0.684210538864136, 0.681818187236786, 0.702222228050232, 0.675438582897186, 
0.672340452671051, 0.683544278144836, 0.678260862827301, 0.675555527210236, 
0.684444427490234, 0.690582931041718, 0.658536612987518, 0.677966117858887, 
0.696832597255707, 0.688372075557709, 0.666666686534882, 0.675675690174103, 
0.684684693813324, 0.678899109363556, 0.669724762439728, 0.663755476474762, 
0.666666686534882, 0.682027637958527, 0.690265476703644, 0.681034505367279, 
0.681614339351654, 0.666666686534882, 0.6822429895401, 0.676190495491028, 
0.689320385456085, 0.673076927661896, 0.639344274997711, 0.641975283622742, 
0.657777786254883, 0.660633504390717, 0.648648619651794, 0.649572670459747, 
0.658634543418884, 0.647773265838623, 0.646288216114044, 0.625, 
0.635593235492706, 0.658008635044098, 0.675675690174103, 0.64840179681778, 
0.669683277606964, 0.660792946815491, 0.646017670631409, 0.633484184741974, 
0.627802670001984, 0.644067823886871, 0.645161271095276, 0.652719676494598, 
0.652360498905182, 0.672340452671051, 0.677966117858887, 0.653061211109161, 
0.640316188335419, 0.639999985694885, 0.646808505058289, 0.623376607894897, 
0.617283940315247, 0.62601625919342, 0.622406661510468, 0.641350209712982, 
0.641350209712982, 0.644897937774658, 0.61599999666214, 0.617283940315247, 
0.629032254219055, 0.622047245502472, 0.65040647983551, 0.663793087005615, 
0.678414106369019, 0.675555527210236, 0.6721311211586, 0.653386473655701, 
0.653543293476105, 0.649999976158142, 0.646288216114044, 0.646288216114044, 
0.622406661510468, 0.624505937099457, 0.61176472902298, 0.61176472902298, 
0.630350172519684, 0.623574137687683, 0.638461530208588, 0.647540986537933, 
0.666666686534882, 0.660792946815491, 0.652360498905182, 0.661224484443665, 
0.658436238765717, 0.65040647983551, 0.643137276172638, 0.666666686534882, 
0.66945606470108, 0.655319154262543, 0.658008635044098, 0.652892589569092, 
0.647773265838623, 0.635593235492706, 0.639004170894623, 0.651162803173065, 
0.628787875175476, 0.625954210758209, 0.65587043762207, 0.693693697452545, 
0.696832597255707, 0.693333327770233, 0.644897937774658, 0.642857134342194, 
0.653225779533386, 0.672199189662933, 0.678260862827301, 0.693333327770233, 
0.690909087657928, 0.663636386394501, 0.649999976158142, 0.648000001907349, 
0.629482090473175, 0.637795269489288, 0.60966545343399, 0.641791045665741, 
0.666666686534882, 0.656126499176025, 0.669354856014252, 0.677824258804321, 
0.67256635427475, 0.669527888298035, 0.658436238765717, 0.675105512142181, 
0.678571403026581, 0.678571403026581, 0.6875, 0.703196346759796, 
0.676056325435638, 0.657407402992249, 0.642276406288147, 0.633587777614594, 
0.63670414686203, 0.620437979698181, 0.669291317462921, 0.648221373558044, 
0.658634543418884, 0.677824258804321, 0.684210538864136, 0.68085104227066, 
0.680672287940979, 0.70175439119339, 0.63589745759964, 0.623115599155426, 
0.636815905570984, 0.628019332885742, 0.603773593902588, 0.626865684986115, 
0.624390244483948, 0.636771321296692, 0.651162803173065, 0.660194158554077, 
0.676328480243683, 0.676328480243683, 0.679245293140411, 0.660377383232117, 
0.654028415679932, 0.669856488704681, 0.657407402992249, 0.669603526592255, 
0.657894730567932, 0.660465121269226, 0.642857134342194, 0.632034659385681, 
0.646017670631409, 0.64069265127182, 0.623376607894897, 0.629310369491577, 
0.613445401191711, 0.638888895511627, 0.653658509254456, 0.673076927661896, 
0.679245293140411, 0.669811308383942, 0.6822429895401, 0.669767439365387, 
0.666666686534882, 0.646766185760498, 0.682692289352417, 0.679245293140411, 
0.672985792160034, 0.669902920722961, 0.643776834011078, 0.642533957958221, 
0.666666686534882, 0.672985792160034, 0.646464645862579, 0.656084656715393, 
0.656084656715393, 0.677083313465118, 0.663265287876129, 0.670103073120117, 
0.686567187309265, 0.67980295419693, 0.657004833221436, 0.669856488704681, 
0.646766185760498, 0.663316607475281, 0.689655184745789, 0.670000016689301, 
0.649484515190125, 0.659898459911346, 0.649214684963226, 0.66304349899292, 
0.685082852840424, 0.65193372964859, 0.648936152458191, 0.645161271095276, 
0.636363625526428, 0.650602400302887, 0.658823549747467, 0.674033164978027, 
0.663101613521576, 0.659685850143433, 0.659793794155121, 0.65625, 
0.655737698078156, 0.659459471702576, 0.663212418556213, 0.673575103282928, 
0.663157880306244, 0.676923096179962, 0.609523832798004, 0.64390242099762, 
0.639593899250031, 0.64615386724472, 0.642105281352997, 0.617801070213318, 
0.610837459564209, 0.6169154047966, 0.604166686534882, 0.642105281352997, 
0.626865684986115, 0.656410276889801, 0.659340679645538, 0.659217894077301, 
0.670212745666504, 0.64039409160614, 0.64039409160614, 0.634146332740784, 
0.62135922908783, 0.642201840877533, 0.640350878238678, 0.660714268684387, 
0.644549787044525, 0.660465121269226, 0.654028415679932, 0.650943398475647, 
0.618181824684143, 0.618181824684143, 0.628019332885742, 0.614634156227112, 
0.630136966705322, 0.627802670001984, 0.607476651668549, 0.615384638309479, 
0.623762369155884, 0.637168169021606, 0.61224490404129, 0.609442055225372, 
0.597510397434235, 0.611111104488373, 0.651376128196716, 0.649999976158142, 
0.643564343452454, 0.650943398475647, 0.638497650623322, 0.650943398475647, 
0.64390242099762, 0.663316607475281, 0.653061211109161, 0.613861382007599, 
0.636771321296692, 0.616666674613953, 0.588709652423859, 0.605577707290649, 
0.611111104488373, 0.606299221515656, 0.617886185646057, 0.65765768289566, 
0.634361207485199, 0.648648619651794, 0.65727698802948, 0.645161271095276, 
0.639639616012573, 0.639639616012573, 0.64840179681778, 0.638095259666443, 
0.682464480400085, 0.679611623287201, 0.632653057575226, 0.630541861057281, 
0.648148119449615, 0.629629611968994, 0.638888895511627, 0.622807025909424, 
0.623481810092926, 0.605809152126312, 0.633484184741974, 0.685990333557129, 
0.682926833629608, 0.663316607475281, 0.607929527759552, 0.632478654384613, 
0.657777786254883, 0.657534241676331, 0.666666686534882, 0.672727286815643, 
0.688995242118835, 0.682692289352417, 0.637681186199188, 0.638888895511627, 
0.631111085414886, 0.619834721088409, 0.635294139385223, 0.625, 
0.636363625526428, 0.651162803173065, 0.638497650623322, 0.663551390171051, 
0.666666686534882, 0.656716406345367, 0.658008635044098, 0.651785731315613, 
0.679069757461548, 0.666666686534882, 0.666666686534882, 0.682692289352417, 
0.69523811340332, 0.685185194015503, 0.644859790802002, 0.633484184741974, 
0.61924684047699, 0.618644058704376, 0.625592410564423, 0.666666686534882, 
0.673076927661896, 0.669902920722961, 0.656862735748291, 0.663507103919983, 
0.657407402992249, 0.663507103919983), .Dim = c(x = 20L, y = 10L, 
year = 11L))), dimensions = structure(list(x = structure(list(
    from = 1, to = 20, offset = 632475, delta = 30, refsys = "+proj=utm +zone=36 +datum=WGS84 +units=m +no_defs ", 
    point = FALSE, values = NULL), class = "dimension"), y = structure(list(
    from = 1, to = 10, offset = 3438015, delta = -30, refsys = "+proj=utm +zone=36 +datum=WGS84 +units=m +no_defs ", 
    point = FALSE, values = NULL), class = "dimension"), year = structure(list(
    from = 1, to = 11L, offset = NA_real_, delta = NA_real_, 
    refsys = NA_character_, point = NA, values = c("yr_2000", 
    "yr_2001", "yr_2002", "yr_2003", "yr_2004", "yr_2005", "yr_2006", 
    "yr_2007", "yr_2008", "yr_2009", "yr_2010")), class = "dimension")), raster = structure(list(
    affine = c(0, 0), dimensions = c("x", "y"), curvilinear = FALSE), class = "stars_raster"), class = "dimensions"), class = "stars")


RunMK = function(ci_stars) {
	window = 5
	num_years = dim(ci_stars)[3]
	yrs = seq((num_years - window) + 1)
	mk_stat = list()
	cl = makeCluster(4)
	for (yr in yrs) {
		last_yr = ((yr + window)-1)
	########################################
	# This works...
	# stars_window = ci_stars[,,,2:6]
	# This does not...
		stars_window = ci_stars[,,,yr:last_yr]
	#########################################
	print(paste("Doing window number:" , as.character(yr)))
	# Here I want to run run mk.test with st_apply using parallel
		mk_stat[[yr]] = stars::st_apply(stars_window,
                              MARGIN = c('x','y'),
                              CLUSTER = cl,
                              FUN=function(z) {trend::mk.test(x = z,
                                      alternative = "two.sided",
                                      continuity = TRUE)$statistic})
	}	
	stopCluster(cl)
}

RunMK(ci_stars)
_______________________________________________
R-sig-Geo mailing list
R-sig-Geo@r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-geo

Reply via email to