Put potatoes in a large glass bowl and cover with cold water; set aside.
Prepare pie crust mix according to package directions; wrap in plastic and set aside.
Using a food processor or food grater, coarsely grate Cheddar cheese. Put in a small bowl; add flour and toss to mix well.
Preheat oven to 350°F.
Lightly grease a shallow two quart oval, round or rectangular baking dish.
Drain potatoes thoroughly; pat dry with paper towels. Alternately layer potatoes with sliced onion, ham and cheese-flour mixture, sprinkling with garlic, salt, pepper and nutmeg as you layer.
Pour on milk; dot with butter and set aside.
On a lightly floured surface, roll pastry out to a 15 x 11 inch rectangle, or a 13 inch circle, depending on the size and shape of your baking dish. Gently lift pastry and place on baking dish to cover potato mixture completely.
Turn edges of pastry under and flute decoratively with your fingers. Cut four gashes in pastry to allow steam to escape while baking.
Mix egg yolk with one tablespoon of the half and half cream; brush over the pastry to glaze.
Bake 60 minutes or until pstry is golden brown and potatoes are done.
Remove from oven; pour remaining half and half cream through the vents in the top of the pastry. Let stand 15 minutes before serving.