Where would I find FindEmptyVars

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Where would I find FindEmptyVars

Art Kendall
I went to the <Extensions><Extension Hub> and entered FindEmptyVars.
with all 3 State check boxes checked. and Select all checked.

"No extensions match the specified criteria."

I get the same message with very check box checked.  

If I click the link for Prerequisites it tells me the integration plug-in
for Python is installed.

begin program.
IMPORT spssaux2

spssaux2.FindEmptyVars()
end program.

points to the first "2" character and says "invalid syntax"



-----
Art Kendall
Social Research Consultants
--
Sent from: http://spssx-discussion.1045642.n5.nabble.com/

=====================
To manage your subscription to SPSSX-L, send a message to
[hidden email] (not to SPSSX-L), with no body text except the
command. To leave the list, send the command
SIGNOFF SPSSX-L
For a list of commands to manage subscriptions, send the command
INFO REFCARD
Art Kendall
Social Research Consultants
Reply | Threaded
Open this post in threaded view
|

Re: Where would I find FindEmptyVars

Jon Peck
FindEmptyVars is in the spssaux2.py module, which is installed with Statistics.  You got the error message because import must be in lower case.

Here is the documentation for FindEmptyVars (from the spssaux2.py module).

def FindEmptyVars(vars=None, delete=False, alpha=True):
    """Scan specified or all variables and determine which are missing or blank for all cases.  
    Return list of names and optionally delete those variables.
   
    vars is a list of the (zero-based) index numbers of the variables to check.
    It can also be a single string of blank-separated numbers or a VariableDict object.  
    By default, all  variables are checked.  
    A value is considered empty if it is sysmis or user missing.
    String variables are also considered empty if their values are all blank.
    delete specifies whether empty variables should be deleted or not.
    The return value is a possibly empty list of variable names, not index numbers.
   
    If alpha is False, string variables are excluded from the checked list.  This is true
    even if the variable was listed in the vars parameter.
   
    Examples:
    # find but do not delete the empty variables
    print FindEmptyVars()

    # use a VariableDict object and do the same thing
    vard = spssaux.VariableDict()
    print FindEmptyVars(vars=vard)
   
    # use a string of variable numbers and do the same thing but delete the empty variables
    strvars = []
    for v in vard:
        strvars.append(str(int(v)))
    strvars = " ".join(strvars)
    print FindEmptyVars(vars=strvars, delete=True)

On Fri, Mar 20, 2020 at 8:48 AM Art Kendall <[hidden email]> wrote:
I went to the <Extensions><Extension Hub> and entered FindEmptyVars.
with all 3 State check boxes checked. and Select all checked.

"No extensions match the specified criteria."

I get the same message with very check box checked. 

If I click the link for Prerequisites it tells me the integration plug-in
for Python is installed.

begin program.
IMPORT spssaux2

spssaux2.FindEmptyVars()
end program.

points to the first "2" character and says "invalid syntax"



-----
Art Kendall
Social Research Consultants
--
Sent from: http://spssx-discussion.1045642.n5.nabble.com/

=====================
To manage your subscription to SPSSX-L, send a message to
[hidden email] (not to SPSSX-L), with no body text except the
command. To leave the list, send the command
SIGNOFF SPSSX-L
For a list of commands to manage subscriptions, send the command
INFO REFCARD


--
Jon K Peck
[hidden email]

===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD
Reply | Threaded
Open this post in threaded view
|

Re: Where would I find FindEmptyVars

Art Kendall
Thank you.



-----
Art Kendall
Social Research Consultants
--
Sent from: http://spssx-discussion.1045642.n5.nabble.com/

=====================
To manage your subscription to SPSSX-L, send a message to
[hidden email] (not to SPSSX-L), with no body text except the
command. To leave the list, send the command
SIGNOFF SPSSX-L
For a list of commands to manage subscriptions, send the command
INFO REFCARD
Art Kendall
Social Research Consultants