public class AndroidLauncher extends AndroidApplication {
@Override
protected void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
AndroidApplicationConfiguration config = new AndroidApplicationConfiguration();
initialize(new MyGdxGame(), config);
}
}
public class AndroidApplication extends Activity implements AndroidApplicationBase
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.mygdx.game" >
<uses-sdk android:minSdkVersion="9" android:targetSdkVersion="26" />
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/GdxTheme" >
<activity
android:name="com.mygdx.game.AndroidLauncher"
android:label="@string/app_name"
android:screenOrientation="landscape"
android:configChanges="keyboard|keyboardHidden|orientation|screenSize">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>
import pandas as pd
from io import StringIO
import re
data = """
col1,col2
1,2.0
2,0.5
3,2
tt,2
4,1
5,F
1,G
"""
regex = r"[^0-9\.]+"
df = pd.read_csv(StringIO(data),sep=',')
for col in df.columns:
filter = df[col].str.contains(regex)
df = df.drop(df[col][filter].index)
print(df)