Blender Calculator Input Issues

How would I use Blender to create a GUI for a Python calculator I made?

It’s not a standard scientific calculator, its for genetics, and requires 6 fields of data to be entered but no operators. I can’t find a way for the script to access the entered data. Also, I have fields where any character can entered, but I only want numbers.

Python Script:

#########################################################################
#
#   Hardy-Weinburg Solver:
#   Generational Selection Calculator
#
#   Version 1.2.1
#   
#########################################################################


print "
============================================================================= 
"
print "Hardy-Weinburg Solver:"
print "Multi-Generation Selection Calculator (v.1.2.1)"
print "
(c)2010 

f = 0         #Number of Generations calculated
p = 0         #Dominant Allele Frequency
q = 0         #Recessive Allele Frequency
dHom = 0      #% of population dominant homozygous
dHomSR = 0    #dominant homozygous survival rate
dHomS = 0     #% survived after selection
het = 0       #% of population heterozygous
hetSR = 0     #heterozygous survival rate
hetS = 0      #% survived after selection
rHom = 0      #% of population recessive homozygous  
rHomSR = 0    #recessive homozygous survival rate
rHomS = 0     #% survived after selection
cont = ""
calc = 1      #Current calculation #
print_all = "n"
no_select = "n"
bar = "
============================================================================= 
"
perr = "
 #####################  Input Percentage Error!  ########################### 
"

#  ============================Input Data:================================  #

print bar

print "Solver Initiated:"

while True:
    print "Calculation {0}
".format(calc)
    
#   Input Data: all data set in DECIMAL form!
   
    dHom = input (" % Homozygous Dominant: ")
    if dHom > 1:
        dHom = dHom *.01
        if dHom >= 1:
            print perr
            break
        
    dHomSR = input("     % survival: ")
    if dHomSR >= 1:
        dHomSR = dHomSR *.01
        if dHomSR > 1:
            print perr
            break
        
    het = input  (" 
 % Heterozygous: ")
    if het >= 1:
        het = het *.01
        if het > 1:
            print perr
            break
        
    hetSR = input ("     % survival: ")
    if hetSR >= 1:
        hetSR = hetSR *.01
        if hetSR > 1:
            print perr
            break
        
    rHom = 1 - het - dHom
    print (" 
 % Homozygous Recessive: {0}%").format(rHom*100)
        
    rHomSR = input("     % survival: ")
    if rHomSR >= 1:
        rHomSR = rHomSR *.01
        if rHomSR > 1:
            print perr
            break

    f = input("
 # Generations: ")
##    if f > 100:
##        print " That's many generations!"
##        cont = raw_input ("
Continue? (y/n): ")
##        if cont != "y":
##                break    
        
    print_all = raw_input(" 
 print all generation frequencies? (y/n): ")
    if print_all != "y":
        print_all = "n"
        if f > 100 and print_all == "y":
            print " That's a lot to print!"
            cont = raw_input ("
 Continue? (y/n): ")
            if cont != "y":
                    break

##    no_select = raw_input("print generation frequencies before selection occurrs? (y/n): ")
##    if print_all != "y":
##        print_all = "n"
    
    print bar
            
#  =============================Calculations:==============================  #

#   Parent Generation

    #Calculate allele frequencies
    if print_all == "y": 
        q = ((rHom) ** (.5))
        p = 1-q

        print "
 Parent Generation:
"
        print " Dominant Allele Frequency =  {0}".format (p)
        print " Recessive Allele Frequency = {0}".format (q)
        print " % Homozygous Dominant =      {0}%".format (dHom*100)
        print " % Heterozygous =             {0}%".format (het*100)
        print " % Homozygous Recessive =     {0}%".format (rHom*100)    


#   First Generation

    #Calculate number of animals survived
    dHomS = (dHom * dHomSR)
    hetS = (het * hetSR)
    rHomS = (rHom * rHomSR)

    #Reset frequencies to = 100
    dHom = dHomS * (1/(dHomS+hetS+rHomS))
    het = hetS * (1/(dHomS+hetS+rHomS))
    rHom = rHomS * (1/(dHomS+hetS+rHomS))

    #Calculate allele frequencies
    p = (2*dHom + het)/(2*(dHom+het+rHom))
    q = 1 - p

    if print_all == "y" or f == 1: 
        print "

 Generation 1:
"
        print " Dominant Allele Frequency =  {0}".format (p)
        print " Recessive Allele Frequency = {0}".format (q)
        print " % Homozygous Dominant =      {0}%".format (dHom*100)
        print " % Heterozygous =             {0}%".format (het*100)
        print " % Homozygous Recessive =     {0}%".format (rHom*100)  
        
#  ======================Multi-Generation Calculator:=======================  #

#   Loops until current generation is equal to total generations
    generation_current = 2    
    while generation_current <= f:
        
        #redistribute HW frequencies
        dHom = p*p
        het = 2*p*q
        rHom = q*q

        #number survived
        dHomS = (dHom * dHomSR)
        hetS = (het * hetSR)
        rHomS = (rHom * rHomSR)

        # set to 100
        dHom = dHomS * (1/(dHomS+hetS+rHomS))
        het = hetS * (1/(dHomS+hetS+rHomS))
        rHom = rHomS * (1/(dHomS+hetS+rHomS))

        #Calculate allele frequencies
        p = (2*dHom + het)/(2*(dHom+het+rHom))
        q = 1 - p
                
        if generation_current < f and print_all == "y" : 
            print "

 Generation {0}:
".format(generation_current)
            print " Dominant Allele Frequency =  {0}".format (p)
            print " Recessive Allele Frequency = {0}".format (q)
            print " % Homozygous Dominant =      {0}%".format (dHom*100)
            print " % Heterozygous =             {0}%".format (het*100)
            print " % Homozygous Recessive =     {0}%".format (rHom*100)

        elif generation_current == f:
            print "

 Generation {0}:
".format(f)
            print " Dominant Allele Frequency =  {0}".format (p)
            print " Recessive Allele Frequency = {0}".format (q)
            print " % Homozygous Dominant =      {0}%".format (dHom*100)
            print " % Heterozygous =             {0}%".format (het*100)
            print " % Homozygous Recessive =     {0}%".format (rHom*100)
            print bar
            calc = calc + 1 #sets the current calculation # up by one after entire calculation id done

        generation_current = generation_current + 1  

    
    







EDIT:
quote missing at end of line 14
print "
©2010 "