The artist intended it to be a display of his love for the city: white plastic bags stamped with the “I ♥ NY” logo lighted from within and glowing moonlike from lampposts and trees in Brooklyn and beyond. Almost immediately, the installation attracted attention, though probably not the kind the artist, Takeshi Miyakawa, expected.

The police bomb squad was called and Mr. Miyakawa, 50, was arrested early Saturday.

On Sunday, a judge ordered him to be held pending a psychological evaluation, his lawyer said.

Mr. Miyakawa’s plan was to place white LED lights in the plastic bags and hang the bags around the city.