Yes, you can liberally use portions of ResearchKit code to build your app.
ResearchKit's license is BSD-like, so you can use ResearchKit code in any way you see fit provided you comply with its three points:
Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
Neither the name of the copyright holder(s) nor the names of any contributors may be used to endorse or promote products derived from
this software without specific prior written permission. No license is
granted to the trademarks of the copyright holders even if such marks
are included in this software.
This won't probably apply to your case, given that you only want to use parts of the ResearchKit code, but if you want to advertise the fact that you app uses ResearchKit, you may do so as explained at the footer here:
You may use the ResearchKit mark in order to indicate that your
product uses or is compatible with the ResearchKit software (for
example, “for use with,” “for,” or “compatible with" ResearchKit)
provided that:
- The product does in fact use ResearchKit software developed by the ResearchKit.org open source project;
- The ResearchKit mark stands apart from your brand or trademark (e.g., as in “ResearchKit for Chromium")
- You do not seek to register a trademark containing ResearchKit or the ResearchKit logo; and
- You do not state or imply in any way that Apple endorses, sponsors or guarantees your product, or was involved in or
associated with its development.