RPM measurement using Arduino Mega and Matlab

I want to measure simulated engine rpm signal with Arduino Mega and import the data in Matlab for further processing. I am using Matlab R2015a. please suggest how to I exchange data between Arduino IDE and Matlab 2015a.

Have a look at their package