I want to be able to create a list and choice column with PowerShell but the Choice column always fails. I have found a few examples showing my code to work so I must be missing something.

[MSDN Link to Add field](https://msdn.microsoft.com/en-us/library/ms477246.aspx)

```
clear
Add-PSSnapin Microsoft.SharePoint.PowerShell

function CreateCustomList($siteCollectionUrl, $listName, $listTitle, $listDescription) {
    $spWeb = Get-SPWeb -Identity $siteCollectionUrl  
    $spTemplate = $spWeb.ListTemplates["Custom List"]  
    $spListCollection = $spWeb.Lists  
    $spListCollection.Add($listName, $listDescription, $spTemplate)  
    $path = $spWeb.url.trim()

    #set display name
    $spList = $spWeb.GetList("$path/Lists/$listName")
    $spList.Title = $listTitle
    $spList.Update()

    return $spList
}  

function AddChoiceField($spList, $title){
    #create choices collection
    $choices = New-Object System.Collections.Specialized.StringCollection
    $choices.Add("Completed") | Out-Null
    $choices.Add("Pending") | Out-Null
    $choices.Add("Not Applicable") | Out-Null

    #create choice field
    $name = $title -replace '\s',''
    $spFieldType = [Microsoft.SharePoint.SPFieldType]::Choice
    $name = $spList.Fields.Add($name, 
        [Microsoft.SharePoint.SPFieldType]::Choice, 
        $false, 
        $false, 
        $choices);

    #Set display Name
    $spCol = $spList.Fields[$name]
    $spCol.Title = $title
    $spCol.Update()
}

$siteCollectionUrl = "http://URL"  
$listName = "CustomCheckList"
$listTitle = "Custom Checklist"
$listDescription = "This checklist is used because of reasons"

$spList = CreateCustomList $siteCollectionUrl $listName $listTitle $listDescription
AddChoiceField $spList, "First checklist item"

```

Edit:
Here is the error message returned

```
Cannot find an overload for "Add" and the argument count: "5".
At line:11 char:5
+     $name = $spList.Fields.Add($name,
+     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodException
    + FullyQualifiedErrorId : MethodCountCouldNotFindBest

Exception setting "Title": "Object reference not set to an instance of an object."
At line:19 char:5
+     $spCol.Title = $title
+     ~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], SetValueInvocationException
    + FullyQualifiedErrorId : ExceptionWhenSetting

```