Tutorial by Examples

This example shows how to use column data to set a MultiIndex in a pandas.DataFrame. In [1]: df = pd.DataFrame([['one', 'A', 100], ['two', 'A', 101], ['three', 'A', 102], ...: ['one', 'B', 103], ['two', 'B', 104], ['three', 'B', 105]], ...: columns=['c1'...
It's easier to implement some UDFs on the worksheet if full column references can be passed in as parameters. However, due to the explicit nature of coding, any loop involving these ranges may be processing hundreds of thousands of cells that are completely empty. This reduces your VBA project (and ...
Some things all beginners should know / do that will help them have a good start with VB .Net: Set the following Options: 'can be permanently set ' Tools / Options / Projects and Soluntions / VB Defaults Option Strict On Option Explicit On Option Infer Off Public Class Form1 End Class ...
The Windows.Forms.Timer component can be used to provide the user information that is not time critical. Create a form with one button, one label, and a Timer component. For example it could be used to show the user the time of day periodically. 'can be permanently set ' Tools / Options / Projec...
An Option is a data structure that contains either a single value, or no value at all. An Option can be thought of as collections of zero or one elements. Option is an abstract class with two children: Some and None. Some contains a single value, and None contains no value. Option is useful in ex...
You can think of an OperationQueue as a line of tasks waiting to be executed. Unlike dispatch queues in GCD, operation queues are not FIFO (first-in-first-out). Instead, they execute tasks as soon as they are ready to be executed, as long as there are enough system resources to allow for it. Get th...
The Foundation framework provides the Operation type, which represents a high-level object that encapsulates a portion of work that may be executed on a queue. Not only does the queue coordinate the performance of those operations, but you can also establish dependencies between operations, create c...
<svg xmlns="http://www.w3.org/2000/svg" version="1.1"> <polyline points="10,5 25,15 20,10" /> </svg>
public class SignUpActivity extends BaseAppCompatActivity { @BindView(R.id.tIETSignUpEmail) EditText mEditEmail; @BindView(R.id.tIETSignUpPassword) EditText mEditPassword; @Override protected void onCreate(@Nullable Bundle savedInstanceState) { super.onCrea...
public class LoginActivity extends BaseAppCompatActivity { @BindView(R.id.tIETLoginEmail) EditText mEditEmail; @BindView(R.id.tIETLoginPassword) EditText mEditPassword; @Override protected void onResume() { super.onResume(); FirebaseUser firebaseUs...
public class ForgotPasswordActivity extends AppCompatActivity { @BindView(R.id.tIETForgotPasswordEmail) EditText mEditEmail; private FirebaseAuth mFirebaseAuth; private FirebaseAuth.AuthStateListener mAuthStateListener; @Override protected void onCreate(Bundle saved...
public class ChangeEmailActivity extends BaseAppCompatActivity implements ReAuthenticateDialogFragment.OnReauthenticateSuccessListener { @BindView(R.id.et_change_email) EditText mEditText; private FirebaseUser mFirebaseUser; @OnClick(R.id.btn_change_email) void onChangeE...
public class ChangePasswordActivity extends BaseAppCompatActivity implements ReAuthenticateDialogFragment.OnReauthenticateSuccessListener { @BindView(R.id.et_change_password) EditText mEditText; private FirebaseUser mFirebaseUser; @OnClick(R.id.btn_change_password) void on...
public class ReAuthenticateDialogFragment extends DialogFragment { @BindView(R.id.et_dialog_reauthenticate_email) EditText mEditTextEmail; @BindView(R.id.et_dialog_reauthenticate_password) EditText mEditTextPassword; private OnReauthenticateSuccessListener mOnReauthenticat...
Java configuration is typically done by applying the @Configuration annotation to a class to suggest that a class contains bean definitions. The bean definitions are specified by applying the @Bean annotation to a method that returns an object. @Configuration // This annotation tells the Applicati...
Xml configuration is typically done by defining beans within an xml file, using Spring's specific beans schema. Under the root beans element, typical bean definition would be done using the bean subelement. <?xml version="1.0" encoding="UTF-8"?> <beans xmlns="htt...
Autowiring is done using a sterotype annotation to specify what classes are going to be beans in the ApplicationContext, and using the Autowired and Value annotations to specify bean dependencies. The unique part of autowiring is that there is no external ApplicationContext definition, as it is all...
Setting Up the database public class DatabaseHelper extends SQLiteOpenHelper { // Database Version private static final int DATABASE_VERSION = 1; // Database Name private static final String DATABASE_NAME = "database_name"; // Table Names private static...
Hadoop Distributed File System (HDFS) is a Java-based file system that provides scalable and reliable data storage that is designed to span large clusters of commodity servers. HDFS, MapReduce, and YARN form the core of Apache™ Hadoop®. HDFS is designed to be highly fault-tolerant, which is achieve...
STEP 1: CREATE A DIRECTORY IN HDFS, UPLOAD A FILE AND LIST CONTENTS Let’s learn by writing the syntax. You will be able to copy and paste the following example commands into your terminal: hadoop fs -mkdir: Takes the path URI’s as an argument and creates a directory or multiple directories. Usag...

Page 514 of 1336