fix previous error
fix previous error

I made an error about median absolute error before. This commit fixes previous error using the median_absolute_deviation within astropy.stats package. Also, the bug mentioned in astropy#7125 is not really a bug for the code, it is rather a bug for the data. Therefore, I propose to raise an error to inform user that there's something wrong with the data.
stargaser/astropy,saimn/astropy,dhomeier/astropy,larrybradley/astropy,saimn/astropy,saimn/astropy,lpsinger/astropy,dhomeier/astropy,aleksandr-bakanov/astropy,aleksandr-bakanov/astropy,pllim/astropy,astropy/astropy,stargaser/astropy,astropy/astropy,lpsinger/astropy,bsipocz/astropy,bsipocz/astropy,mhvk/astropy,pllim/astropy,dhomeier/astropy,stargaser/astropy,StuartLittlefair/astropy,astropy/astropy,stargaser/astropy,pllim/astropy,astropy/astropy,saimn/astropy,larrybradley/astropy,aleksandr-bakanov/astropy,larrybradley/astropy,lpsinger/astropy,larrybradley/astropy,MSeifert04/astropy,MSeifert04/astropy,saimn/astropy,lpsinger/astropy,aleksandr-bakanov/astropy,dhomeier/astropy,StuartLittlefair/astropy,bsipocz/astropy,mhvk/astropy,mhvk/astropy,StuartLittlefair/astropy,mhvk/astropy,pllim/astropy,dhomeier/astropy,mhvk/astropy,MSeifert04/astropy,larrybradley/astropy,StuartLittlefair/astropy,astropy/astropy,bsipocz/astropy,pllim/astropy,StuartLittlefair/astropy,MSeifert04/astropy,lpsinger/astropy