Jake Wharton hasn't released it in maven as an aar. There's a group though that has made an aar of it available through their server, you can set it up like this in your build.gradle:
Add this to your source repositories after you declare your plugins:
repositories {
maven { url "http://dl.bintray.com/populov/maven" }
mavenCentral()
}
This will source their maven repo, which contains a packaged aar that they put together. Once that's done, you can simply add this line to your dependencies and everything should work once you sync your project with your gradle files.
dependencies {
// ...
compile 'com.viewpagerindicator:library:2.4.1@aar'
// ...
}
We use it in our app if you'd like to see a working example: https://github.com/pandanomic/SUREwalk_android/blob/master/surewalk/build.gradle
EDIT: Android Studio generates two build.gradle files for projects now, make sure you put this in the right one!