You can use the following workaround to also include comma as a valid input:-
Through XML:
<EditText
android:inputType="number"
android:digits="0123456789.," />
Programmatically:
EditText input = new EditText(THE_CONTEXT);
input.setKeyListener(DigitsKeyListener.getInstance("0123456789.,"));
In this way Android system will show the numbers' keyboard and allow the input of comma. Hope it helps :)
Not tested
A variation on the 'digit' solutions offered here:
Taking into account the locale separator.
Font: https://stackoverflow.com/a/34256139/7482458