Check out example codes for "rxswift map". It will help you in understanding the concepts better.

Code Example 1

func transformUsingMap() -> Observable<String> {
    return Observable.of(1, 2, 3)
        .map { String("\($0)") }
}

func arrayToNewObject(items: [Item]) -> [Data] {
   return items.map({ item in 
                   return Data(item)
       })
}

Learn ReactJs, React Native from akashmittal.com