This is my checkbox. How do I programmatically uncheck or check the checkbox via a function?

`<input name="Purchased" [(ngModel)]="Purchased" type="checkbox" id="test1" />` 

`<label for="test1">Purchased Item</label>`