modified matlab_port to improve support of getting scalar params