Combining multiple bands from different image collection into one collection Unicorn Meta Zoo #1: Why another podcast? Announcing the arrival of Valued Associate #679: Cesar ManaraImporting Sentinel-1 Image Collection to Google Earth Engine APIEarth Engine sampleRegions: keep track of original pixels geometry/location?Merging two image collection into one with two bands (LST and NDVI )Randomly splitting Feature Collection in Google Earth Engine?Merging Aqua + Terra MODIS image collectionsMedian image of merged image collectionsSet property disappears in ImageCollection mapped function (Earth Engine)Calculate yearly mean/median in merged Landsat image collectionData organization in Google Earth Engine image collection?How to use the reducer.mean function to average multiple data points?

Second order approximation of the loss function (Deep learning book, 7.33)

Can you stand up from being prone using Skirmisher outside of your turn?

Arriving in Atlanta after US Preclearance in Dublin. Will I go through TSA security in Atlanta to transfer to a connecting flight?

Did the Roman Empire have penal colonies?

Is Bran literally the world's memory?

A strange hotel

How to avoid introduction cliches

Expansion//Explosion and Siren Stormtamer

How to use @AuraEnabled base class method in Lightning Component?

Where did Arya get these scars?

My admission is revoked after accepting the admission offer

What is the term for a person whose job is to place products on shelves in stores?

Why did Israel vote against lifting the American embargo on Cuba?

How can I wire a 9-position switch so that each position turns on one more LED than the one before?

Book with legacy programming code on a space ship that the main character hacks to escape

Split coins into combinations of different denominations

Married in secret, can marital status in passport be changed at a later date?

Error: Syntax error. Missing ')' for CASE Statement

A Paper Record is What I Hamper

Reattaching fallen shelf to wall?

Can I criticise the more senior developers around me for not writing clean code?

What's parked in Mil Moscow helicopter plant?

Is a 5 watt UHF/VHF handheld considered QRP?

Has a Nobel Peace laureate ever been accused of war crimes?



Combining multiple bands from different image collection into one collection



Unicorn Meta Zoo #1: Why another podcast?
Announcing the arrival of Valued Associate #679: Cesar ManaraImporting Sentinel-1 Image Collection to Google Earth Engine APIEarth Engine sampleRegions: keep track of original pixels geometry/location?Merging two image collection into one with two bands (LST and NDVI )Randomly splitting Feature Collection in Google Earth Engine?Merging Aqua + Terra MODIS image collectionsMedian image of merged image collectionsSet property disappears in ImageCollection mapped function (Earth Engine)Calculate yearly mean/median in merged Landsat image collectionData organization in Google Earth Engine image collection?How to use the reducer.mean function to average multiple data points?



.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








1















I did some calculations on variety of image collections and have generated products and saved them in variables, say a, b and c. Now I want to combine all these products (All one bands) into a multiband image collection.



What function should i use?
I tried with:



a.combine(b).combine(c)
a.merge(b).merge(c)
a.add(b).add(c)


But, these functions are not working.










share|improve this question









New contributor




Ramla is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.


























    1















    I did some calculations on variety of image collections and have generated products and saved them in variables, say a, b and c. Now I want to combine all these products (All one bands) into a multiband image collection.



    What function should i use?
    I tried with:



    a.combine(b).combine(c)
    a.merge(b).merge(c)
    a.add(b).add(c)


    But, these functions are not working.










    share|improve this question









    New contributor




    Ramla is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.






















      1












      1








      1








      I did some calculations on variety of image collections and have generated products and saved them in variables, say a, b and c. Now I want to combine all these products (All one bands) into a multiband image collection.



      What function should i use?
      I tried with:



      a.combine(b).combine(c)
      a.merge(b).merge(c)
      a.add(b).add(c)


      But, these functions are not working.










      share|improve this question









      New contributor




      Ramla is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.












      I did some calculations on variety of image collections and have generated products and saved them in variables, say a, b and c. Now I want to combine all these products (All one bands) into a multiband image collection.



      What function should i use?
      I tried with:



      a.combine(b).combine(c)
      a.merge(b).merge(c)
      a.add(b).add(c)


      But, these functions are not working.







      google-earth-engine






      share|improve this question









      New contributor




      Ramla is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.











      share|improve this question









      New contributor




      Ramla is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      share|improve this question




      share|improve this question








      edited 2 days ago









      PolyGeo

      54k1782246




      54k1782246






      New contributor




      Ramla is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      asked 2 days ago









      RamlaRamla

      242




      242




      New contributor




      Ramla is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.





      New contributor





      Ramla is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






      Ramla is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.




















          1 Answer
          1






          active

          oldest

          votes


















          3














          Assuming you made a unique name for each band, and that you want to obtain one image with 3 bands (one for a, one for b and one for c) you have to addBands, like this:



          var a = ee.Image(1).rename('one') // product one
          var b = ee.Image(2).rename('two')
          var c = ee.Image(3).rename('three')

          var final = a.addBands([b, c])


          link: https://code.earthengine.google.com/5c3ceef589fc8cbe6036f8f2ef22f2ca






          share|improve this answer























          • I tried with this one already. It works on single images, but not on image collections.

            – Ramla
            yesterday











          • The combine function works for three bands, but combining more then 3 prompts the error of empty ImageCollection

            – Ramla
            yesterday











          • You should show your code and error message, at least a link to the code editor

            – Rodrigo E. Principe
            yesterday











          • code.earthengine.google.com/1060f78574bd1d88c437f2b54ec5c36a

            – Ramla
            yesterday











          • This is why you must post all the code (or a code that can reproduce the error) when you make the question.. combine function is what you need, but you are trying to combine collections that have images with different IDs, and if you see combine documentation it says that combines by ID, so when applying a join it doesn't find a match. If you want to join by date, you have to make the process yourself (join first and then add bands)

            – Rodrigo E. Principe
            yesterday











          Your Answer








          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "79"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );






          Ramla is a new contributor. Be nice, and check out our Code of Conduct.









          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fgis.stackexchange.com%2fquestions%2f319501%2fcombining-multiple-bands-from-different-image-collection-into-one-collection%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          3














          Assuming you made a unique name for each band, and that you want to obtain one image with 3 bands (one for a, one for b and one for c) you have to addBands, like this:



          var a = ee.Image(1).rename('one') // product one
          var b = ee.Image(2).rename('two')
          var c = ee.Image(3).rename('three')

          var final = a.addBands([b, c])


          link: https://code.earthengine.google.com/5c3ceef589fc8cbe6036f8f2ef22f2ca






          share|improve this answer























          • I tried with this one already. It works on single images, but not on image collections.

            – Ramla
            yesterday











          • The combine function works for three bands, but combining more then 3 prompts the error of empty ImageCollection

            – Ramla
            yesterday











          • You should show your code and error message, at least a link to the code editor

            – Rodrigo E. Principe
            yesterday











          • code.earthengine.google.com/1060f78574bd1d88c437f2b54ec5c36a

            – Ramla
            yesterday











          • This is why you must post all the code (or a code that can reproduce the error) when you make the question.. combine function is what you need, but you are trying to combine collections that have images with different IDs, and if you see combine documentation it says that combines by ID, so when applying a join it doesn't find a match. If you want to join by date, you have to make the process yourself (join first and then add bands)

            – Rodrigo E. Principe
            yesterday















          3














          Assuming you made a unique name for each band, and that you want to obtain one image with 3 bands (one for a, one for b and one for c) you have to addBands, like this:



          var a = ee.Image(1).rename('one') // product one
          var b = ee.Image(2).rename('two')
          var c = ee.Image(3).rename('three')

          var final = a.addBands([b, c])


          link: https://code.earthengine.google.com/5c3ceef589fc8cbe6036f8f2ef22f2ca






          share|improve this answer























          • I tried with this one already. It works on single images, but not on image collections.

            – Ramla
            yesterday











          • The combine function works for three bands, but combining more then 3 prompts the error of empty ImageCollection

            – Ramla
            yesterday











          • You should show your code and error message, at least a link to the code editor

            – Rodrigo E. Principe
            yesterday











          • code.earthengine.google.com/1060f78574bd1d88c437f2b54ec5c36a

            – Ramla
            yesterday











          • This is why you must post all the code (or a code that can reproduce the error) when you make the question.. combine function is what you need, but you are trying to combine collections that have images with different IDs, and if you see combine documentation it says that combines by ID, so when applying a join it doesn't find a match. If you want to join by date, you have to make the process yourself (join first and then add bands)

            – Rodrigo E. Principe
            yesterday













          3












          3








          3







          Assuming you made a unique name for each band, and that you want to obtain one image with 3 bands (one for a, one for b and one for c) you have to addBands, like this:



          var a = ee.Image(1).rename('one') // product one
          var b = ee.Image(2).rename('two')
          var c = ee.Image(3).rename('three')

          var final = a.addBands([b, c])


          link: https://code.earthengine.google.com/5c3ceef589fc8cbe6036f8f2ef22f2ca






          share|improve this answer













          Assuming you made a unique name for each band, and that you want to obtain one image with 3 bands (one for a, one for b and one for c) you have to addBands, like this:



          var a = ee.Image(1).rename('one') // product one
          var b = ee.Image(2).rename('two')
          var c = ee.Image(3).rename('three')

          var final = a.addBands([b, c])


          link: https://code.earthengine.google.com/5c3ceef589fc8cbe6036f8f2ef22f2ca







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered 2 days ago









          Rodrigo E. PrincipeRodrigo E. Principe

          4,54111021




          4,54111021












          • I tried with this one already. It works on single images, but not on image collections.

            – Ramla
            yesterday











          • The combine function works for three bands, but combining more then 3 prompts the error of empty ImageCollection

            – Ramla
            yesterday











          • You should show your code and error message, at least a link to the code editor

            – Rodrigo E. Principe
            yesterday











          • code.earthengine.google.com/1060f78574bd1d88c437f2b54ec5c36a

            – Ramla
            yesterday











          • This is why you must post all the code (or a code that can reproduce the error) when you make the question.. combine function is what you need, but you are trying to combine collections that have images with different IDs, and if you see combine documentation it says that combines by ID, so when applying a join it doesn't find a match. If you want to join by date, you have to make the process yourself (join first and then add bands)

            – Rodrigo E. Principe
            yesterday

















          • I tried with this one already. It works on single images, but not on image collections.

            – Ramla
            yesterday











          • The combine function works for three bands, but combining more then 3 prompts the error of empty ImageCollection

            – Ramla
            yesterday











          • You should show your code and error message, at least a link to the code editor

            – Rodrigo E. Principe
            yesterday











          • code.earthengine.google.com/1060f78574bd1d88c437f2b54ec5c36a

            – Ramla
            yesterday











          • This is why you must post all the code (or a code that can reproduce the error) when you make the question.. combine function is what you need, but you are trying to combine collections that have images with different IDs, and if you see combine documentation it says that combines by ID, so when applying a join it doesn't find a match. If you want to join by date, you have to make the process yourself (join first and then add bands)

            – Rodrigo E. Principe
            yesterday
















          I tried with this one already. It works on single images, but not on image collections.

          – Ramla
          yesterday





          I tried with this one already. It works on single images, but not on image collections.

          – Ramla
          yesterday













          The combine function works for three bands, but combining more then 3 prompts the error of empty ImageCollection

          – Ramla
          yesterday





          The combine function works for three bands, but combining more then 3 prompts the error of empty ImageCollection

          – Ramla
          yesterday













          You should show your code and error message, at least a link to the code editor

          – Rodrigo E. Principe
          yesterday





          You should show your code and error message, at least a link to the code editor

          – Rodrigo E. Principe
          yesterday













          code.earthengine.google.com/1060f78574bd1d88c437f2b54ec5c36a

          – Ramla
          yesterday





          code.earthengine.google.com/1060f78574bd1d88c437f2b54ec5c36a

          – Ramla
          yesterday













          This is why you must post all the code (or a code that can reproduce the error) when you make the question.. combine function is what you need, but you are trying to combine collections that have images with different IDs, and if you see combine documentation it says that combines by ID, so when applying a join it doesn't find a match. If you want to join by date, you have to make the process yourself (join first and then add bands)

          – Rodrigo E. Principe
          yesterday





          This is why you must post all the code (or a code that can reproduce the error) when you make the question.. combine function is what you need, but you are trying to combine collections that have images with different IDs, and if you see combine documentation it says that combines by ID, so when applying a join it doesn't find a match. If you want to join by date, you have to make the process yourself (join first and then add bands)

          – Rodrigo E. Principe
          yesterday










          Ramla is a new contributor. Be nice, and check out our Code of Conduct.









          draft saved

          draft discarded


















          Ramla is a new contributor. Be nice, and check out our Code of Conduct.












          Ramla is a new contributor. Be nice, and check out our Code of Conduct.











          Ramla is a new contributor. Be nice, and check out our Code of Conduct.














          Thanks for contributing an answer to Geographic Information Systems Stack Exchange!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fgis.stackexchange.com%2fquestions%2f319501%2fcombining-multiple-bands-from-different-image-collection-into-one-collection%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          How does Billy Russo acquire his 'Jigsaw' mask? Unicorn Meta Zoo #1: Why another podcast? Announcing the arrival of Valued Associate #679: Cesar Manara Favourite questions and answers from the 1st quarter of 2019Why does Bane wear the mask?Why does Kylo Ren wear a mask?Why did Captain America remove his mask while fighting Batroc the Leaper?How did the OA acquire her wisdom?Is Billy Breckenridge gay?How does Adrian Toomes hide his earnings from the IRS?What is the state of affairs on Nootka Sound by the end of season 1?How did Tia Dalma acquire Captain Barbossa's body?How is one “Deemed Worthy”, to acquire the Greatsword “Dawn”?How did Karen acquire the handgun?

          Личност Атрибути на личността | Литература и източници | НавигацияРаждането на личносттаредактиратередактирате

          A sequel to Domino's tragic life Why Christmas is for Friends Cold comfort at Charles' padSad farewell for Lady JanePS Most watched News videos