add unit convert function, so that we would accept option include unit, e.g. 12g