# Rejoin to Building

![](https://3405893330-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-Ma9gBkJelXEQ5LsYEl7%2Fuploads%2Fgit-blob-1de5ebadf696f48f8b7473e748a47308479fb3a0%2FRejoin_to_Building.png?alt=media)

![](https://3405893330-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-Ma9gBkJelXEQ5LsYEl7%2Fuploads%2Fgit-blob-49d1a496fdae16b6a606eaeca82a3de53f0f798f%2FRejoin_to_Building.png?alt=media) - [\[source code\]](https://github.com/ladybug-tools/dragonfly-grasshopper/blob/master/dragonfly_grasshopper/src/DF%20Rejoin%20to%20Building.py)

Rejoin a list of Room2Ds that were originally a part of a Building back to a new Building with updated Room2Ds.

In the event that the input contains Room2Ds that were not a part of an original Building, this component can still be used but the stories will be regenerated based on the Room2D floor elevations and a warning will be given.

### Inputs

* **room2ds \[Required]**

A list of Dragonfly Room2D objects to be re-joined into Buildings.

### Outputs

* **buildings**

Dragonfly Buildings containing the input Room2Ds. This may be multiple buildings when the input Room2Ds originally had several different parent buildings.
