You can do what you want easily if you declare your variable as discussed HERE.
So if we are to apply it, you can open your workbook like this:
    Dim wb As Workbook
    Dim myfilename As String
    myfilename = "C:\Users\Ayaz\Desktop\Analysis\AvgStdev.xlsm"
    '~~> open the workbook and pass it to workbook object variable
    Set wb = Workbooks.Open(myfilename) 
    '~~> More codes here
Now later in your code if you are saving the same file:
    wb.Save '~~> save
    wb.Close '~~> close
Or you can do it using Close method only:
    wb.Close True '~~> explicit SaveChanges argument to true
Now if however you like to save it as another file:
    Dim newfilename As String
    newfilename = "C:\Users\Ayaz\Desktop\Analysis\Another.xlsm"
    '~~> If you are saving it in a format other than .xlsx,
    '~~> you have to be explicit in the FileFormat argument
    wb.SaveAs newfilename, xlOpenXMLWorkbookMacroEnabled
    wb.Close
HTH.