I need a floating GPIO pin

digitalWrite(D1, 0);
pinMode(D1, OUTPUT);
delay(100);
pinMode(D1, INPUT);