Angular UI / select2 multiple how to preselect values/options?

Problem

using angular-ui with select2 as follows:

<select ui-select2 ng-model="search.categories" multiple style="width:300px" data-placeholder="select category">
<option value="open" >open</option>
<option value="close" >close</option>
</select>

Where and how should I preselect options? By default selected option is only first.Somehow in controller?

Problem courtesy of: Jakub Kuchar

Solution

For a simple <select> list it's easy:

MyController function($scope) {
$scope.search = {
categories: 'close'
};
}

For <input> it gets trickier because you may need to add a initSelection option

Solution courtesy of: ProLoser

View additional discussion.