Remove dmdAnalArg and replace by easier to understand code