Molecular control of electric conductivity and structural properties of polymers of pyrrole derivatives