function [am] = AAM(varargin)
am.elements = {};
am.imageDirectory = '';
am.imageFilenames = {};
am.modelName = '';
am.modelDirec = '';
am.pdmDirec = '';
am.pdmName = '';
am.sfamDirec = '';
am.sfamName = '';
am.currentEntity = '';
am.rootDir = '';
am.currentEntityNumber = -1;
am.PointModelTemplate = PointModelTemplate;
am.activeElements = [];
am.completeElements = [];
am.procrustesParams.rotation = 1;
am.procrustesParams.scaling = 1;
am.procrustesParams.translation = 1;
am.pdm = [];
am.pointset = 0;
am.imageset = 0;
am.pointindices = [];
am.am_imagenames = {};
% Temperary, until pdmwalk is re-written
am.options = [];
switch nargin
    case 0
    case 1
        am.elements = varargin{1};
    otherwise
        error('Invalid number of input parameters');
end
am = class(am, 'AAM');

