I making an android app which need to display data analysis in Gantt Chart.
I implement this library from https://github.com/PhilJay/MPAndroidChart and it runs smoothly in my app.

But what I'm worrying is if this library has been removed from github repo, will my app get effected?

affected?

yes, affected

Presumably you will have downloaded that library and incorporated it into your deliverable, so nothing that happens on GitHub will affect it.
It it were removed I'd be more worried about (a) confirming that its licence allows you to continue to do what you are doing and (b) what will happen when that library needs to be updated for some future change in Android?

@James, is there a way we can know whether the license allow us continue to use?

While you would need an attorney to weigh in I think https://github.com/PhilJay/MPAndroidChart/blob/master/LICENSE covers the licensed use very well as it looks to be the bog standard Apache 2.0 license.

Lines 123 to 128 are interesting as it may impact what you write in your own license agreement. Remember that I did not read all 201 lines but you should.

PS. As to your top question I could spend a day going over that question but given no one can code it all, you should use code and content so you can build your apps. Imagine trying to start over from say a single board computer, assembly language to OS to apps written all by you. While I applaud such efforts, at some point we have to move beyond "I wrote every line of code."