0

So I am interested in making a list from {10,11,12,1,2,3,4,5) which actually represents months from {October, November,...May} of the following year. However I keep getting a list error. Is there actually a better way of writing this script. Find code below

var list = ee.List.sequence(10, 5);
print(list, 'FromOct2000-May2001')

1 Answer 1

2

You can first make the list from 10 to 12 and then the list from 1 to 5 and simply concatenate them using cat.

var list = ee.List.sequence(10, 12).cat(ee.List.sequence(1, 5));
1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.