filter

filter() - filter the grid by given filter expression. More about filter expression you can find here:
http://www.shieldui.com/documentation/datasource/javascript/filtering

 $(function () {
     $("#grid").shieldGrid({
         dataSource: {
             data: gridData,
             filter: {
                 and: [
                     { path: "name", filter: "contains", value: "b" },
                     {
                         or: [
                             { path: "gender", filter: "eq", value: "male" },
                             { path: "name", filter: "startswith", value: "c" }
                         ]
                     }
                 ]
             },
             schema: {
                 fields: {
                     id: { type: "number" },
                     name: { type: "string" },
                     company: { type: "string" },
                     phone: { type: "string" },
                     age: { type: "number" }
                }
            }  
         },
         columns: [
             { field: "id", width: "70px", title: "ID" },
             { field: "name", title: "Person Name", width: "170px" },
             { field: "company", title: "Company" },
             { field: "phone", title: "Phone", width: "170px" },
             { field: "age", title: "Age" }
         ]
     });
});
function myCustomFilter() {
     $("#grid").swidget().filter({ path: "name", filter: "contains", value: "A" });
}