On Tue, 15 Nov 2016, George Matysiak wrote:
When I select a sample using > *Restrict, based in criterion *and
then > *Use
dummy variable* all works fine, and I get the appropriate sub-set. When I
then select > *Random sub-sample* from this subset, everything is fine as
long as the number selected is less than the number of items that were
selected on the first call.
However, there is a misleading message *Number of observations to select
(max x)*, where x is greater than the number of observations that were
selected on the first call.
Could you send (offlist is probably better) the dataset, and tell me
which dummy variable you are restricting on? After such a restriction,
the max number of cases for random sub-sampling is supposed to be 1
less than the number of observations. And I find that to be the case
in the examples I've tried.
One example: open the credscore.gdt dataset that's supplied with
gretl. Sub-sample on the dummy variable Acc. This leaves 73
observations. Then go to /Sample/Random sub-sample: the max shown is
72.
Allin Cottrell