示例#1
0
int varnum_from_string (const char *str, DATASET *dset)
{
    int v = positive_int_from_string(str);

    if (v <= 0 || v >= dset->v) {
	v = -1;
    } 
    
    return v;
}
示例#2
0
文件: datawiz.c 项目: aylusltd/gretl
static int default_start_decade (void)
{
    int d = 1700;

    if (dataset->S != NULL) {
	d = positive_int_from_string(dataset->S[0]);
    }
    
    if (d < 0) {
	d = 1700;
    }

    return d;
}