Although there's anamoly with respect to position of hydrogen. But it is placed in group 1. Why in group 1 and why nin in group 17?
Hydrogen is placed in first group as it has ns1 electronic configuration likewise all the alkali metals have this configuration.However,varies greatly from the alkali metals as it forms cations (H+) more reluctantly than the other alkali metal.
We can say hydrogen is naughty element as it shows dual behaviour,it shows both metallic and non-metallic behaviour ;metallic with non metals and non metallic with metals respectively.
Although ,it has properties similar to those of halogens too and can be placed in group 17 too.It has different in its properties than all elements of periodic table.
I think,because of its more dominating metallic properties thou as no. of non-metals discovered upto now is greater than the no. of metals,to get in reactions with non metals ,so it dominates the property of metal to form compound with non metal.Hence i think scientists kept Hydrogen in first group but not in 17th group at the time of discovery of periodic table.