{% extends "api.html" %} {% block api_content %}
Chicago Boss provides API functions for sending and receiving emails. No SMTP configuration or server is necessary.
The easiest way to send a message is:
If you want to treat Body as an io_lib format string and pass in arguments, use this format:
If you need to customize the email headers or wish to generate emails from Django templates, read on.
If the simple method doesn't meet your needs, Chicago Boss provides a way to send email using controllers and views.
Mail controller logic should go into src/mail/my_application_outgoing_mail_controller.erl
in your project directory, and templates should go into src/mail/view/
. To send an email from a web controller, call:
That will invoke outgoing_mail_controller:foo_message(Arg1, Arg2, ...)
and use the return value to populate the templates src/mail/view/foo_message.txt
and src/mail/view/foo_message.html
, then send the email in a background process. Your mail controller function should return:
If the return value is nevermind
, no email will be sent. Otherwise,
FromAddress
is the sender's email address. The address should not be in "friendly" form, i.e<EMAIL_ADDRESS>is OK, but "Kai Foo<EMAIL_ADDRESS>is not.
ToAddress
is recipient's email address.
HeaderFields
is a proplist of email header fields, e.g. [{"From", "SECRETARY TO CHARLES TAYLOR<EMAIL_ADDRESS>{"Subject", "Unclaimed Lottery Winnings"}]
.
If you want the From: and To: fields to appear in the message, you need to provide values here; they will not be taken from FromAddress
and ToAddress
.
However, the header fields for Message-ID: and Date: will be populated automatically if not provided.
Variables
(if present) will be passed to the associated Django template(s), which will form the body of the message.
Options
(if present) is a proplist of additional options, possibly containing:
attachments
- a list of tuples representing email attachments. Each attachment should consist of: {FileName, MimeType, Contents}
. In this case FileName
simply refers to how the file will be named in the email (and is not necessarily a file on the local file system). The file's Contents
should be an io_list.
template
- a string with the name of another template to use for rendering (assuming you don't want the default template, which is just the same as the function name).
Formatting. If templates ending only in ".txt" are present, the message will be sent in plain-text; if templates ending only in ".html" are present, the message will be sent as HTML; but if both ".txt" and ".html" templates are present, the message will be sent as a a MIME multi-part message with alternative plain-text and HTML representations.
I18n. To use Chicago Boss's i18n machinery in emails, specify the desired language in the "Content-Language" header field returned from the mail controller.
To receive email, you must first enable the SMTP server in your configuration. You can then define endpoints in src/mail/my_application_incoming_mail_controller.erl
. Each function should take two arguments:
The return value is ignored.
To implement authentication for incoming email, simply define an authorize_/3
function in your incoming mail controller. It should take three arguments:
The authorize_/3
function should return true
if the user should be permitted to send email to the controller, or false
otherwise.


Children describe technology that gives them a sense of ambiguity as 'creepy' Researchers have defined for the first time what children mean when they say technology is 'creepy.'
Ed Charbeneau: .NET, JavaScript, and C# articles Articles about software development, HTML5, C#, and ASP.NET, .NET Core.
SMS for 2FA: What Are Your Security Options? - Authy Two-factor authentication is about using something in addition to your username and password for authentication. That “something” falls into three main categories, something you know (i.e. your social security number), something you have (i.e. a cell phon...
Hack on Stack Overflow exposes private data for ~250 users Intruders who accessed production system remained undetected for at least five days.
brunoproduit/roca Implementation of the ROCA attack. Contribute to brunoproduit/roca development by creating an account on GitHub.


| DOSE: |
4800 mg |
oral |
Piracetam |
(daily) |
| |
400 mg |
oral |
DMAE |
(daily) |
| |
1 tablet |
oral |
Vitamins / Supplements |
|
Mindset: Clear concise, yet tired from rave.
I was turned on to Piracetam after having experienced Modafinil for a while. Modafinil is great I just don't feel like staying up all the time. Though I did like the increased memory and cognitive ability(s).
After taking into concern what I was putting my body through while sleeping only every other day, I decided to try Piracetam. There are many different 'racetams' out there but this one seemed to be the safest and affected most people that tried it. There are others but they seem to have a higher failure rate and one or two have some nasty effect on the liver.
I found the taste of Piracetam to be horrid and decided that at the dosages I would be taking, I should invest in a capsule machine.
2x800mg Piracetam - 3 times a day (spaced about 4-6hours apart)
1x200mg DMAE - 2 times a day (spaced about 8 hours apart)
1x Mens 1-A-Day Multi-vitamin
I noticed clear benefits the first day after the attack dosage (roughly 4 grams, sometimes not necessary for everyone). I felt more aware of my surroundings and had a general feeling of being on my game. These effects disappeared for 2 days only to reappear and grow stronger over time. (this seems to happen in alot of cases)
As a martial artist and a type2 diabetic I pay attention to what my body is doing more than most and I've grown quite attuned to how I feel and what's causing that feeling. The first thing I noticed was increased reflexes. My neuro-kinetics are great to begin with, they are noticably better now. Things fall in slo-mo from time to time. My general attitude is better. Being more on top of things and having less procrastination seems to be a benefit as well. Anxiety is a thing of the past. I feel like I have the patience of a tibetan monk now.
I don't believe my dopamine levels are raised from Piracetam or DMAE, however they may be slightly increased due to how well I'm accomplishing things in my daily life now.
The most pleasant effect was noticed about a week after starting. My blood sugar no longer seems to be a factor in my daily life! My life usually revolves around my blood sugar being too high or too low, causing me to feel sluggish and sleepy, almost stoned.
After researching, Piracetam increases brain glucose usage and metabolism up to 25%, this percentage being different for everyone. THATS DAMN SIGINIFICANT! Not only that, but the same mechanism causes the blood in the brain to carry slightly more oxygen! I've never been more amazed!
Think of the nasty drugs that MD's prescribe for Diabetes and though they help, they can also damage other systems. Now I find something that has no LD50 and is so non-toxic that the FDA sees no reason to regulate it? I'm ecstatic!
I notice now that I'm eating smaller meals more often. Not by choice, but because of the increase in metabolic rate and usage of glucose.
Other welcome effects...
* Vivid long-term memory recall. I have good recall to begin with, but now I can remember experiences I've had years ago in tremendous detail.
* Increased ambi-dexterity. Training with weapons in either hand is much easier now. My training partners are becoming scared at my increased understanding of techniques and ability to use either side of my body to enact them.
* Increased speed. They are even more scared of the slightly increased neuro-kinetics.
* Slight strength increase. Maybe because of stronger or more efficient signals to nerves?
* Greater ability to multi-task without getting confused. (self explanatory)
So far I haven't found any problems while using alcohol, marijuana, or modafinil. Though alcohol and marijuana have the opposite effect of what I'm trying to achieve.
I'm now free of the daily struggle that was food. I still eat right and even better in some cases as the sugar cravings are gone. Now I have more of a genuine 'belly hunger' when I need to eat.
I make sure I have a choline source as Piracetam depletes this from the system. This depletion is usually denoted by headaches.
Experience Reports are the writings and opinions of the individual authors who submit them.
Some of the activities described are dangerous and/or illegal and none are recommended by Erowid.


The Digital Chroma makes a certain part of its internal file system accessible over the Ethernet interface using the SMB networking protocol (which is what Windows uses natively, MacOS understands, and which Linux accesses via a Samba client). The machine name is "Chroma#", where # is a digit in the range 1 through 9 set by the {Chroma_number} calibration setting, to allow for multiple Digital Chromas on the same network. The share name is simply "chroma". (These names may be displayed by the computer in upper case.) So, in Windows, assuming the default setting of 1, one could open the folder "\\\\CHROMA1\\CHROMA" and see the nine program subdirectories and various other files.
When this is first opened, it asks for a username and password. The username can be anything, and the default password is "1234567890", but the latter can be changed via the {Chroma_password} setting.


--- layout: post title: "Backupninja!" date: 2010-12-24 21:14:51 +0000 permalink: /2010/12/24/backupninja/ category: Linux tags: - Linux - Open Source - Backup redirect_from: - /blog/backupninja/ ---
I don't know how I missed it before, but I found a great backup tool today. It's BackupNinja. It's stupidly simple to set up to back up a small number of machines. It's no centralized backup system like bacula, but for a single server or two (like I have) it seems far better than a "roll your own" solution.
So, a big Christmas thank you to the BackupNinja devs.


### What is a Graph? A Graph is a data structure that models objects and pairwise relationships between them with nodes and edges. For example: Users and friendships, locations and paths between them, parents and children, etc.
### Why is it important to learn Graphs? Graphs represent relationships between data. Anytime you can identify a relationship pattern, you can build a graph and often gain insights through a traversal. These insights can be very powerful, allowing you to find new relationships, like users who have a similar taste in music or purchasing.
### How many types of graphs are there? Graphs can be directed or undirected, cyclic or acyclic, weighted or unweighted. They can also be represented with different underlying structures including, but not limited to, adjacency lists, adjacency matrices, object and pointers, or a custom solution.
### What is the time complexity (big-O) to add/remove/get a vertex/edge for a graph? It depends on the implementation. (Graph Representations). Before choosing an implementation, it is wise to consider the tradeoffs and complexities of the most commonly used operations.


Senior IT professional who effectively partners with top level business executives and division presidents to craft, align and execute IT strategy to achieve strategic business objectives and growth and profit targets. Extensive business, accounting (CPA) and technology leadership experience. Outstanding track record of delivering effective and cost-efficient information systems solutions. High energy performer who implements positive change within organizations.
As an Executive Partner at Gartner, I partner with Executive Program members to provide strategic research, executive-level advice and mentoring, while working with the entire Gartner service delivery team to provide programs and services to address their most pressing issues and opportunities. I also get my clients really drunk at working dinners and then convince them to hire my daughter Laura. Shh!
To contact me, please use the contact information on my resume.


@(params: Map[String, Any]) @uk.gov.hmrc.hmrcemailrenderer.templates.helpers.html.template_main(params, "Verify your email address") {
You’re getting this email because you’re applying to use a venture capital scheme. We need you to confirm your email address so you can use the service.
To verify your email address click the link below:
From HM Revenue and Customs, Small Company Enterprise Centre
}


The Health Diet Survey
Do you eat red meat? Why? Why not? Help us find out what the people think!
Name
Email
Number
one
two
three
four
Red Meat
White Meat
Other
I eat pasta
I eat pasta
I eat pasta
Thank you for checking our page
Submit


Filter
Airports
Type
Filter By Search
Small
Medium
Large
Heliport
Closed
In Your Favorites
Name
ICAO
IATA
Elev.
Lat.
Long.
Type
Showing 5-8 of 10,382 results


Vocabulary for AcknowledgementDetailType
Description
Codes classifying the severity of the issue carried in the acknowledgement. This is a UK localised version of the HL7 vocabulary.
Values:
|
Version: |
03 |
|
Date: |
25th November 2004 |
|
Code |
Description |
Note |
|
ER |
Error |
The acknowledgement identifies an error. |
|
WG |
Warning |
The acknowledgement identifies an issue which is a warning. |
|
IF |
For Information |
The acknowledgement identifies an issue for information. |


Avalon Floral is a locally owned and operated (Sandy O'Connell) small boutique-type shop in Eau Claire, Wisconsin. We usually know our customers, their tastes, and their families. Avalon sets itself apart by being a service oriented, custom design, "happy to try to accommodate your every wish" floral shop! Our products, both fresh arrangements and gifts, change frequently. We try hard to be everything that the box stores are NOT. We actually "answer" our telephones. Much of our work "goes out the back door" as we deliver personalized, convenient gifts to your family and friends in a timely manner.
Monday - Friday 9:00AM-5:30PM
Saturdays 9:00AM-1:00PM
(715) 833.880
<EMAIL_ADDRESS>504 Water Street
Eau Claire, WI 54703
Avalon is located in the Historic Water Street District of Eau Claire, Wisconsin.
There is public parking across the street.
For quick pick-ups and for our customers who need very easy access,
please feel free to park behind our back door on the alley.


880-2-7791045-51
Fax: 880-2-7791052
<EMAIL_ADDRESS>Login
|
Jobs
|
Webmail
|
Contact
Home
(current)
Administration
Chancellor
Vice Chancellor
Pro Vice Chancellor
Treasurer
Registrar
Senate
Syndicate
Academic Council
Finance Committee
Calendar
Faculties
Faculty of Arts & Humanities
Faculty of Mathematical & Physical Sciences
Faculty of Social Sciences
Faculty of Biological Sciences
Faculty of Business Studies
Faculty of Law
Institutes
Institute of Business Administration
Institute of Information Technology
Institute of Remote Sensing
Bangabandhu Institute of Comparative Literature and Culture
Center
Medical Centre
Wazed Miah Science Research Center
Students Counselling and Guidance Centre
Centre of Excellence in Teaching & Learning
The Language Centre
Teacher-Student centre
Offices
Registrar Office
Proctor Office
Comptroller Office
Engineering Office
IQAC
ICT Cell
Planning and Development Office
Public Relation Office
Physical Training Office
Office of the Controller of Examinations
Internal Audit Office
University Library
Science Workshop
Transport Office
Accommodations
Mir Mosharraf Hossain Hall
Shaheed Salam-Barkat Hall
Bangabandhu Sheikh Mujibur Rahman Hall
Al Beruni Hall
Shaheed Rafiq-Jabbar Hall
A F M Kamaluddin Hall
Mowlana Bhashani Hall
Bishwakabi Rabindranath Tagore Hall
Jahanara Imam Hall
Nawab Faizunnesa Hall
Pritilata Hall
Fazilatunnesa Hall
Begum Khaleda Zia Hall
Sheikh Hasina Hall
Bangamata Begum Fazilatunnessa Mujib Hall
Begum Sufia Kamal Hall
People
Campus Life
Auditorium
Central Cafeteria
Image Archive
TSC
Student's Accomodation
Admission
Undergraduate 2017-2018
Graduate
M.Phil & PhD
Weekend Courses
Journals
Misc
NOC & GO
Students Stipend
Registered Graduates List
Home
Office
Comptroller Office
Comptroller Office
Md. Mosanul Kabir
Message From Director
Contents are coming soon!
Contents are coming soon!
Officers & Staffs
Officers List
Staffs List


Call us: +971-XXX-XXXX
USD
EUR
AED
RUBL
Language
English
Arabic
Russian
My Account
Wishlist
Checkout
LOGO
All type
Special
Only best
Latest
Welcome Customer!
Sign in
|
Register
0
Category products
Home
Best category
Great articles
32 Items found
Latest items
Trending
Most Popular
Cheapest
NEW
Quick view
Great item name goes here
$1280
$1980
Add to cart
Quick view
Product name goes here just for demo item
$1280
Add to cart
Quick view
Product name goes here just for demo item
$1280
Add to cart
Quick view
Product name goes here just for demo item
$1280
Add to cart
Quick view
Product name goes here just for demo item
$1280
Add to cart
Quick view
Product name goes here just for demo item
$1280
Add to cart
Quick view
Product name goes here just for demo item
$1280
Add to cart
Quick view
Product name goes here just for demo item
$1280
Add to cart
Previous
1
2
3
Next
Our Featured Services
Reasonable prices
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labor
Customer support 24/7
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labor
Quick delivery
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labor
Download Mobile App


curl --url "http://<IP_ADDRESS>:7783" --data "{\"userpass\":\"$userpass\",\"method\":\"setprice\",\"base\":\"BEER\",\"rel\":\"PIZZA\",\"price\":0.9}" - sell order.
curl --url "http://<IP_ADDRESS>:7783" --data "{\"userpass\":\"$userpass\",\"method\":\"buy\",\"base\":\"BEER\",\"rel\":\"PIZZA\",\"relvolume\":0.1,\"price\":1}" - this buy order will match and swap starts.
But orderbook `curl --url "http://<IP_ADDRESS>:7783" --data "{"userpass":"$userpass","method":"orderbook","base":"BEE...
`847f11c` Legacy/dead code clean up. - artemii235
`6231cc3` More legacy/dead code clean up. - artemii235
`b892941` Temporary ignore test_peers_direct_send test. - artemii235
`527f40d` Restore the MM2.md and put this in repo root. - artemii235
`26630f9` Rewrite main Readme to small and simple version... - artemii235
`847f11c` Legacy/dead code clean up. - artemii235
`6231cc3` More legacy/dead code clean up. - artemii235
`b892941` Temporary ignore test_peers_direct_send test. - artemii235
`527f40d` Restore the MM2.md and put this in repo root. - artemii235
`26630f9` Rewrite main Readme to small and simple version... - artemii235
I resolved the problems, seem like developer instruction is incorrects.
I need to manually edit ~/.agama/config.json because of no dev option in GUI to toggle.
@pbca26 I think the change should be made to either add dev toggle to GUI or update readme to explain to edit the JSON file. What do you want? Maybe can I help to do the fix if you say what to change?
`c2387ed` adds encrypt-wallet doc - gcharang
`7212cb1` adds encrypt-wallet doc and agama multisig docs - gcharang
`c150694` edits to the agama multifig docs - gcharang
`e88d473` Merge branch 'master' into dev - gcharang
`848a0c1` minor edit - gcharang
UPD: this happens only when B node connects to A after the order is placed. If A places order and B is connected already B will see the order in orderbook.


subl
8.10.15
The one emotion for me that always comes up pairing sessions would have to be excitement or as DBC refers to it as an "aha" moment. I choose this emotion because its the one that helps motivate you through DBC and all the work we do to move from unit to unit.  The moment you figure out an issue or a bug is like hitting the last shot buzzer beater. It gets you excited to do more. When this type of emotion occurs in pairing its almost like a huge weight is lifted off your shoulder.
Kind , actionable and specific feedback to me is a productive criticism that helps the other person learn their strengths and weaknesses that are noticeable to your pair. This type of feedback is key to being informative as well as kind. Anyone can write negative feedback but being able to write constructive criticism is the main focus. This way the person is learning what they do right and wrong, without getting down on themselves and being too negative.
Its a great learning tool and also helps tie into vulnerability. Sometimes it can be hard to point out and tell people what they do wrong. Its best to put yourself in their shoes and explain it the same way you would prefer to read it. Make sure it is detailed so they can learn and change those mistakes, as well as focus on what they do best. Being vulnerable to me is okay as long as you don't take things to personally and let the negatives turn into positives. This is the best way to approach the DBC way.


I am a technically proficient engineer with a broad skill set who thrives when facing challenges and tackling complex, long-standing problems. Known for the ability to multi-task and juggle multiple pressing projects simultaneously, meeting all deadlines. I work well with business leaders to understand business issues and define system requirements.
Conversational AI development for the Digital Marketplace application using Python Rasa and SciPy. A new technology for online retraining using Python multithreading to retrain new models on the fly. Server management using Python Sanic and Flask.
Teaching Assistant for a competitive programming class, Eminence. Goals included doubt resolution for students, problem setting, writing testcases and solutions.
A computer vision system for batch resume processing and parsing data to an Excel format file. Used Python OpenCV for computer vision processing and VB.NET for Excel files management.
 I love studying about new research topics with an inclination for Deep Learning and Artificial Intelligence.
I enjoy watching TV shows and listening to good music. Every once in a while I take some time out to read good books and blogs about generally everything to keep myself updated.


Fighting game World
This is a link to myanimelist!
This is a link to Reddit!
This is a link to youtube!


By the way, you should know that your teachers' room numbers are on Infinite Campus.
Also, UGWA has a virtual bell feature, which you can turn on in Options under "Virtual bell."


---
layout: archive
title: Lean Prover Zulip Chat Archive
permalink: 113488general/03821isthereatactic.html
---
The archive URL format has changed. Please find this page at:
https://leanprover-community.github.io/archive/stream/113488-general/topic/is.20there.20a.20tactic.3F.html


(#) Inconsistent Layouts !!! WARNING: Inconsistent Layouts This is a warning. Id : `InconsistentLayout` Summary : Inconsistent Layouts Severity : Warning Category : Correctness Platform : Android Vendor : Android Open Source Project Feedback : https://issuetracker.google.com/issues/new?component=192708 Affects : Kotlin and Java files and resource files Editing : This check can *not* run live in the IDE editor Implementation : [Source Code](https://cs.android.com/android-studio/platform/tools/base/+/mirror-goog-studio-main:lint/libs/lint-checks/src/main/java/com/android/tools/lint/checks/LayoutConsistencyDetector.java) Tests : [Source Code](https://cs.android.com/android-studio/platform/tools/base/+/mirror-goog-studio-main:lint/libs/lint-tests/src/test/java/com/android/tools/lint/checks/LayoutConsistencyDetectorTest.java) Copyright Year : 2013 This check ensures that a layout resource which is defined in multiple resource folders, specifies the same set of widgets. This finds cases where you have accidentally forgotten to add a widget to all variations of the layout, which could result in a runtime crash for some resource configurations when a `findViewById()` fails. There **are** cases where this is intentional. For example, you may have a dedicated large tablet layout which adds some extra widgets that are not present in the phone version of the layout. As long as the code accessing the layout resource is careful to handle this properly, it is valid. In that case, you can suppress this lint check for the given extra or missing views, or the whole layout. (##) Example Here is an example of lint warnings produced by this check: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~text res/layout/layout1.xml:11:Warning: The id "button1" in layout "layout1" is missing from the following layout configurations: layout-xlarge (present in layout) [InconsistentLayout] android:id="@+id/button1" ------------------------- res/layout/layout1.xml:38:Warning: The id "button4" in layout "layout1" is missing from the following layout configurations: layout-xlarge (present in layout) [InconsistentLayout] android:id="@+id/button4" ------------------------- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Here is the source file referenced above: `res/layout/layout1.xml`: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~xml linenumbers <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/RelativeLayout1" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" > <!-- my_id1 is defined in ids.xml, my_id2 is defined in main2, my_id3 does not exist --> <Button android:id="@+id/button1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignBottom="@+id/button5" android:layout_alignLeft="@+id/my_id2" android:layout_alignParentTop="true" android:layout_alignRight="@+id/my_id3" android:layout_alignTop="@+id/my_id1" android:text="Button" /> <Button android:id="@+id/button2" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentLeft="true" android:layout_below="@+id/button1" android:text="Button" /> <Button android:id="@+id/button3" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentLeft="true" android:layout_below="@+id/button2" android:text="Button" /> <Button android:id="@+id/button4" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentLeft="true" android:layout_below="@+id/button3" android:text="Button" /> </RelativeLayout> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ You can also visit the [source code](https://cs.android.com/android-studio/platform/tools/base/+/mirror-goog-studio-main:lint/libs/lint-tests/src/test/java/com/android/tools/lint/checks/LayoutConsistencyDetectorTest.java) for the unit tests for this check to see additional scenarios. The above example was automatically extracted from the first unit test found for this lint check, `LayoutConsistencyDetector.test`. To report a problem with this extracted sample, visit https://issuetracker.google.com/issues/new?component=192708. (##) Suppressing You can suppress false positives using one of the following mechanisms: * Adding the suppression attribute `tools:ignore="InconsistentLayout"` on the problematic XML element (or one of its enclosing elements). You may also need to add the following namespace declaration on the root element in the XML file if it's not already there: `xmlns:tools="http://schemas.android.com/tools"`. * Using a suppression annotation like this on the enclosing element: ```kt // Kotlin @Suppress("InconsistentLayout") fun method() { problematicStatement() } ``` or ```java // Java @SuppressWarnings("InconsistentLayout") void method() { problematicStatement(); } ``` * Using a suppression comment like this on the line above: ```kt //noinspection InconsistentLayout problematicStatement() ``` * Using a special `lint.xml` file in the source tree which turns off the check in that folder and any sub folder. A simple file might look like this: ```xml <?xml version="1.0" encoding="UTF-8"?> <lint> <issue id="InconsistentLayout" severity="ignore" /> </lint> ``` Instead of `ignore` you can also change the severity here, for example from `error` to `warning`. You can find additional documentation on how to filter issues by path, regular expression and so on [here](https://googlesamples.github.io/android-custom-lint-rules/usage/lintxml.md.html). * In Gradle projects, using the DSL syntax to configure lint. For example, you can use something like ```gradle lintOptions { disable 'InconsistentLayout' } ``` In Android projects this should be nested inside an `android { }` block. * For manual invocations of `lint`, using the `--ignore` flag: ``` $ lint --ignore InconsistentLayout ...` ``` * Last, but not least, using baselines, as discussed [here](https://googlesamples.github.io/android-custom-lint-rules/usage/baselines.md.html).


Delegating Rendering to a Renderer
Both MapComponent and AreaComponent delegate all of their rendering to a separate renderer. The section Performing Encoding explains how MapRenderer performs the encoding for MapComponent. This section explains in detail the process of delegating rendering to a renderer using AreaRenderer, which performs the rendering for AreaComponent.
To delegate rendering, you perform these tasks:
Create the Renderer class.
Register the renderer with a render kit by using the @FacesRenderer annotation (or by using the application configuration resource file, as explained in Registering a Custom Renderer with a Render Kit).
Identify the renderer type in the @FacesRenderer annotation or in the component’s tag handler.
Creating the Renderer Class
When delegating rendering to a renderer, you can delegate all encoding and decoding to the renderer, or you can choose to do part of it in the component class. The AreaComponent class delegates encoding to the AreaRenderer class.
The renderer class begins with a @FacesRenderer annotation:
@FacesRenderer(componentFamily = "Area", rendererType = "dukesbookstore.renderers.AreaRenderer") public class AreaRenderer extends Renderer {
The @FacesRenderer annotation registers the renderer class with the JavaServer Faces implementation as a renderer class. The annotation identifies the component family as well as the renderer type.
To perform the rendering for AreaComponent, AreaRenderer must implement an encodeEnd method. The encodeEnd method of AreaRenderer retrieves the shape, coordinates, and alternative text values stored in the ImageArea bean that is bound to AreaComponent. Suppose that the area tag currently being rendered has a value attribute value of "book203". The following line from encodeEnd gets the value of the attribute "book203" from the FacesContext instance.
ImageArea ia = (ImageArea)area.getValue();
The attribute value is the ImageArea bean instance, which contains the shape, coords, and alt values associated with the book203 AreaComponent instance. Configuring Model Data describes how the application stores these values.
After retrieving the ImageArea object, the method renders the values for shape, coords, and alt by simply calling the associated accessor methods and passing the returned values to the ResponseWriter instance, as shown by these lines of code, which write out the shape and coordinates:
writer.startElement("area", area); writer.writeAttribute("alt", iarea.getAlt(), "alt"); writer.writeAttribute("coords", iarea.getCoords(), "coords"); writer.writeAttribute("shape", iarea.getShape(), "shape");
The encodeEnd method also renders the JavaScript for the onmouseout, onmouseover, and onclick attributes. The Facelets page need only provide the path to the images that are to be loaded during an onmouseover or onmouseout action:
<bookstore:area id="map3" value="#{Book203}" onmouseover="resources/images/book_203.jpg" onmouseout="resources/images/book_all.jpg" targetImage="mapImage"/>
The AreaRenderer class takes care of generating the JavaScript for these actions, as shown in the following code from encodeEnd. The JavaScript that AreaRenderer generates for the onclick action sets the value of the hidden field to the value of the current area's component ID and submits the page.
sb = new StringBuffer("document.forms[0]['").append(targetImageId). append("'].src='"); sb.append( getURI(context, (String) area.getAttributes().get("onmouseout"))); sb.append("'"); writer.writeAttribute("onmouseout", sb.toString(), "onmouseout"); sb = new StringBuffer("document.forms[0]['").append(targetImageId). append("'].src='"); sb.append( getURI(context, (String) area.getAttributes().get("onmouseover"))); sb.append("'"); writer.writeAttribute("onmouseover", sb.toString(), "onmouseover"); sb = new StringBuffer("document.forms[0]['"); sb.append(getName(context, area)); sb.append("'].value='"); sb.append(iarea.getAlt()); sb.append("'; document.forms[0].submit()"); writer.writeAttribute("onclick", sb.toString(), "value"); writer.endElement("area");
By submitting the page, this code causes the JavaServer Faces life cycle to return back to the Restore View phase. This phase saves any state information, including the value of the hidden field, so that a new request component tree is constructed. This value is retrieved by the decode method of the MapComponent class. This decode method is called by the JavaServer Faces implementation during the Apply Request Values phase, which follows the Restore View phase.
In addition to the encodeEnd method, AreaRenderer contains an empty constructor. This is used to create an instance of AreaRenderer so that it can be added to the render kit.
The @FacesRenderer annotation registers the renderer class with the JavaServer Faces implementation as a renderer class. The annotation identifies the component family as well as the renderer type.
Identifying the Renderer Type
During the Render Response phase, the JavaServer Faces implementation calls the getRendererType method of the component’s tag handler to determine which renderer to invoke, if there is one.
The getRendererType method of the AreaTag tag handler must return the type associated with the renderer. You identify this type in the rendererType element of the @FacesRenderer annotation for AreaRenderer (or in the renderer-type element in the application configuration resource file, as described in Registering a Custom Renderer with a Render Kit). Here is the getRendererType method from the AreaTag class:
@Override public String getRendererType() { return ("DemoArea"); }
Creating the Component Tag Handler explains more about the getRendererType method.


Framework Setup
For each of our applications, we'll need certain over-arching things set up. All implementations will use RavenDB to store our session data, and we'll also load some posts and pages into the database, so once we start writing the actual handlers for the application, we'll be able to see what we've done.
(This step is currently in work, so there is no code checkpoint for it yet.)
Individual Implementations
Uno - In Depth
Dos - In Depth
Tres - In Depth
Quatro - In Depth
Cinco - In Depth


Includes and declarations for mp.c.
More...
#include <stdio.h>
#include <stdlib.h>
#include <sys/time.h>
#include <time.h>
#include <string.h>
#include <omp.h>
#include <stdbool.h>
#include <math.h>
#include <complex.h>
#include <gd.h>
#include <assert.h>
#include "palette.h"
#include "elapsed.h"
#include "colors.h"
#include "getopt.h"
#include "util.h"
Go to the source code of this file.
|
|
#define | __USE_MINGW_ANSI_STDIO 1 |
| |
|
|
typedef struct timespec | time_spec |
| |
|
|
Array | colors |
| |
|
gdImagePtr | im |
| |
| float | gauss_kernel [3][3] |
| |
| float | lpf_filter_6 [3][3] |
| |
| float | lpf_filter_9 [3][3] |
| |
| float | lpf_filter_10 [3][3] |
| |
| float | lpf_filter_16 [3][3] |
| |
| float | lpf_filter_32 [3][3] |
| |
| float | hpf_filter_1 [3][3] |
| |
| float | intensified_sharpen_kernel [3][3] |
| |
| float | hpf_filter_2 [3][3] |
| |
| float | hpf_filter_3 [3][3] |
| |
Includes and declarations for mp.c.
- Author
- Hugh S. Myers
- Date
- Mon Aug 14 11:22:27 2017
DESCRIPTION
Support file for mp.c. This removes the 'clutter' from the primary file for mp.exe.
- Bug:
- No known bugs.
Definition in file mp.h.
◆ GiveDistanceDBL()
Double implementation of DEMM.
This is the Distance Estimator Method for the Mandelbrot set. It is coded using all double variables.
- Parameters
-
| cp | An instance of the ColorDBL structure holding needed information. |
| iMax | The maximum iteration count. |
- Returns
- The same instance of ColorDBL the function was called with.
Definition at line 476 of file mp.c.
◆ GiveDistanceFLT()
Float implementation of DEMM.
This is the Distance Estimator Method for the Mandelbrot set. It is coded using all float variables.
- Parameters
-
| cp | An instance of the ColorFLT structure holding needed information. |
| iMax | The maximum iteration count. |
- Returns
- The same instance of ColorFLT the function was called with.
Definition at line 417 of file mp.c.
◆ GiveDistanceFLT128()
__float128 implementation of DEMM
This is the Distance Estimator Method for the Mandelbrot set. It is coded using all __float128 variables.
- Parameters
-
| cp | An instance of the Color128 structure holding needed information. |
| iMax | The maximum iteration count. |
- Returns
- The same instance of Color128 the function was called with.
Definition at line 593 of file mp.c.
◆ GiveDistanceLDBL()
Long double implementation of DEMM.
This is the Distance Estimator Method for the Mandelbrot set. It is coded using all long double variables.
- Parameters
-
| cp | An instance of the ColorLDBL structure holding needed information. |
| iMax | The maximum iteration count. |
- Returns
- The same instance of ColorLDBL the function was called with.
Definition at line 535 of file mp.c.
◆ MSetCPMDBL()
Double implementation of MSETCPM.
This is the Continuous Potential Method. It is coded using all double variables.
- Parameters
-
| cp | An instance of the ColorDBL structure holding needed information. |
| iMax | The maximum iteration count. |
- Returns
- The same instance of ColorDBL the function was called with.
Definition at line 684 of file mp.c.
◆ MSetCPMFLT()
Float implementation of MSETCPM.
This is the Continuous Potential Method. It is coded using all float variables.
- Parameters
-
| cp | An instance of the ColorFLT structure holding needed information. |
| iMax | The maximum iteration count. |
- Returns
- The same instance of ColorFLT the function was called with.
Definition at line 649 of file mp.c.
◆ MSetCPMFLT128()
__float128 implementation of MSETCPM
This is the Continuous Potential Method. It is coded using all __float128 variables.
- Parameters
-
| cp | An instance of the Color128 structure holding needed information. |
| iMax | The maximum iteration count. |
- Returns
- The same instance of Color128 the function was called with.
Definition at line 748 of file mp.c.
◆ MSetCPMLDBL()
Long double implementation of MSETCPM.
This is the Continuous Potential Method. It is coded using all long double variables.
- Parameters
-
| cp | An instance of the ColorLDBL structure holding needed information. |
| iMax | The maximum iteration count. |
- Returns
- The same instance of ColorLDBL the function was called with.
Definition at line 716 of file mp.c.
◆ MSetDBL()
Mandelbrot Set using double.
Function to compute the Mandelbrot Set using double variables. This derives an image g.width × g.height, centered at g.center from g.centerX and g.centerY. The complex width is g.diameter. The inner loop is available in 4 methods; ZX, meaning calculate without complex variables, COMPLEX, meaning calculate with complex variables, DEMM, meaning use the Distance Estimator Method for Mandelbrot set and MSETCPM, meaning use the Continuous Potential Method.
- Parameters
-
| P | Parameters structure, a collection of configuration information. |
- Returns
- A Parameters structure g, as modified by the function.
Definition at line 198 of file mp.c.
◆ MSetFLT()
Mandelbrot Set using float.
Function to compute the Mandelbrot Set using float variables. This derives an image g.width × g.height, centered at g.center from g.centerX and g.centerY. The complex width is g.diameter. The inner loop is available in 4 methods; ZX, meaning calculate without complex variables, COMPLEX, meaning calculate with complex variables, DEMM, meaning use the Distance Estimator Method for Mandelbrot set and MSETCPM, meaning use the Continuous Potential Method.
- Parameters
-
| P | Parameters structure, a collection of configuration information. |
- Returns
- A Parameters structure g, as modified by the function.
Definition at line 124 of file mp.c.
◆ MSetFLT128()
Mandelbrot Set using __float128.
Function to compute the Mandelbrot Set using __float128 variables. This derives an image g.width × g.height, centered at g.center from g.centerX and g.centerY. The complex width is g.diameter. The inner loop is available in 4 methods; ZX, meaning calculate without complex variables, COMPLEX, meaning calculate with complex variables, DEMM, meaning use the Distance Estimator Method for Mandelbrot set and MSETCPM, meaning use the Continuous Potential Method.
- Parameters
-
| P | Parameters structure, a collection of configuration information. |
- Returns
- A Parameters structure g, as modified by the function.
Definition at line 346 of file mp.c.
◆ MSetLDBL()
Mandelbrot Set using long double.
Function to compute the Mandelbrot Set using long double variables. This derives an image g.width × g.height, centered at g.center from g.centerX and g.centerY. The complex width is g.diameter. The inner loop is available in 4 methods; ZX, meaning calculate without complex variables, COMPLEX, meaning calculate with complex variables, DEMM, meaning use the Distance Estimator Method for Mandelbrot set and MSETCPM, meaning use the Continuous Potential Method.
- Parameters
-
| P | Parameters structure, a collection of configuration information. |
- Returns
- A Parameters structure g, as modified by the function.
Definition at line 272 of file mp.c.
◆ gauss_kernel
Initial value:= {
{1.0, 2.0, 1.0},
{2.0, 4.0, 2.0},
{1.0, 2.0, 1.0}
}
Definition at line 51 of file mp.h.
◆ hpf_filter_1
Initial value:= {
{0.0, -1.0, 0.0},
{-1.0, 5.0, -1.0},
{0.0, -1.0, 0.0}
}
Definition at line 87 of file mp.h.
◆ hpf_filter_2
Initial value:= {
{-1.0, -1.0, -1.0},
{-1.0, 9.0, -1.0},
{-1.0, -1.0, -1.0}
}
Definition at line 99 of file mp.h.
◆ hpf_filter_3
Initial value:= {
{1.0, -2.0, 1.0},
{-2.0, 5.0, -2.0},
{1.0, -2.0, 1.0}
}
Definition at line 105 of file mp.h.
◆ intensified_sharpen_kernel
| float intensified_sharpen_kernel[3][3] |
Initial value:= {
{-1.0, -1.0, -1.0},
{-1.0, 8.0, -1.0},
{-1.0, -1.0, -1.0}
}
Definition at line 93 of file mp.h.
◆ lpf_filter_10
| float lpf_filter_10[3][3] |
Initial value:= {
{1.0, 1.0, 1.0},
{1.0, 2.0, 1.0},
{1.0, 1.0, 1.0}
}
Definition at line 69 of file mp.h.
◆ lpf_filter_16
| float lpf_filter_16[3][3] |
Initial value:= {
{1.0, 2.0, 1.0},
{2.0, 4.0, 2.0},
{1.0, 2.0, 1.0}
}
Definition at line 75 of file mp.h.
◆ lpf_filter_32
| float lpf_filter_32[3][3] |
Initial value:= {
{1.0, 4.0, 1.0},
{4.0, 12.0, 4.0},
{1.0, 4.0, 1.0}
}
Definition at line 81 of file mp.h.
◆ lpf_filter_6
Initial value:= {
{0.0, 1.0, 0.0},
{1.0, 2.0, 1.0},
{0.0, 1.0, 0.0}
}
Definition at line 57 of file mp.h.
◆ lpf_filter_9
Initial value:= {
{1.0, 1.0, 1.0},
{1.0, 1.0, 1.0},
{1.0, 1.0, 1.0}
}
Definition at line 63 of file mp.h.


Work with containers over the Docker API. Rather than using system calls to interact with a docker client, using the API directly means that we can receive richer information from docker. The interface in the package is automatically generated using the 'OpenAPI' (a.k.a., 'swagger') specification, and all return values are checked in order to make them type stable.
| Version: | 0.9.0 |
| Imports: | crayon, curl (≥ 2.3.0), jsonlite, yaml (≥ 2.1.18) |
| Suggests: | knitr, openssl, redux, reticulate, rmarkdown, testthat, withr |
| Published: | 2018-11-19 |
| Author: | Rich FitzJohn [aut, cre] |
| Maintainer: | Rich FitzJohn <rich.fitzjohn at gmail.com> |
| BugReports: | https://github.com/richfitz/stevedore/issues |
| License: | MIT + file LICENSE |
| URL: | https://github.com/richfitz/stevedore |
| NeedsCompilation: | no |
| SystemRequirements: | docker |
| Language: | en-GB |
| Materials: | README |
| CRAN checks: | stevedore results |
| Reference manual: | stevedore.pdf |
| Vignettes: |
Using docker with stevedore Using docker with stevedore |
| Package source: | stevedore_0.9.0.tar.gz |
| Windows binaries: | r-devel: stevedore_0.9.0.zip, r-release: stevedore_0.9.0.zip, r-oldrel: stevedore_0.9.0.zip |
| OS X binaries: | r-release: not available, r-oldrel: not available |
Please use the canonical form https://CRAN.R-project.org/package=stevedore to link to this page.


Built Strategic data and reporting capabilities for J&J’s global Technology Services organization, including Tableau dashboards and datasets in Cloudera Data Lake environment. Developed dashboards for IT operations reporting, strategic supplier management, technology lifecycle, Scrum & Agile processes, finance, project management and other key domain areas across the organization. Utilized Agile development methods and Design Thinking principles to prioritize work, obtain requirements and build dashboards and reports. Drove increase in users from approximately 300 regular users to over 1200 by following a product-focused approach to team’s data assets
Advocated in creating Tableau Dashboard used for university Enrollment, Retention and Graduation (ERG) Analysis. Extracted, transformed, and loaded data on more than 6,500 students enrolled in Rutgers education programs. Employed MS Excel for maintaining, analyzing student’s information and summarized each semester results
Streamlined daily sales data of the company; managed daily, weekly, monthly data analysis statement and data process monitoring. Delegated and maintained database of 3GB at a fixed period and analyzed existing client data to supply the foundation for marketing decision. Monitored and pre-processed 10 years of client data using SQL and utilized regression models to analyze factors. Integrated trend analysis and graphic representation of each product using 5 + Tableau dashboards


A problem has been detected and Windows has been shut down to prevent damage to your computer.
The problem seems to be caused by the following file: ntoskrnl.exe
CRITICAL_OBJECT_TERMINATION
If this is the first time you've seen this stop error screen, restart your computer. If this screen appears again, follow these steps:
Check to make sure any new hardware or software is properly installed. If this is a new installation, ask your hardware or software manufacturer for any Windows updates you might need.
If problems continue, disable or remove any newly installed hardware or software. Disable BIOS memory options such as caching or shadowing. If you need to use safe mode to remove or disable components, restart your computer, press F8 to select Advanced Startup Options, and then select Safe Mode.
Technical Information:
*** STOP: 0x000000f4 (0x00000006, 0x85d39d48, 0x84c5ceac, 0x82dfcb50)
*** ntoskrnl.exe - Address 0x82c603ca base at 0x82c0b000 DateStamp 0x5147d367


Their majesties are handcrafted in Atkins’ Atlanta studio. The bike frames are fillet brazed (instead of welded) in shop, meaning a bronze filament is heated and used as a sort of glue to bind the pieces together. This sort of frame holds stronger, but takes more time. But that’s a compromise Atkins is willing to make; these bikes are “built for style,” after all
The bike frames are fillet brazed (instead of welded) in shop, meaning a bronze filament is heated and used as a sort of glue to bind the pieces together. This sort of frame holds stronger, but takes more time. But that’s a compromise Atkins is willing to make; these bikes are “built for style,” after all.
The bike frames are fillet brazed (instead of welded) in shop, meaning a bronze filament is heated and used as a sort of glue to bind the pieces together. This sort of frame holds stronger, but takes more time. But that’s a compromise Atkins is willing to make; these bikes are “built for style,” after all.
The bike frames are fillet brazed (instead of welded) in shop, meaning a bronze filament is heated and used as a sort of glue to bind the pieces together. This sort of frame holds stronger, but takes more time. But that’s a compromise Atkins is willing to make; these bikes are “built for style,” after all.
Each piece has been carefully sourced from artisans around the country, with a few exceptions for the more technical bits, allowing each bike to have its own unique qualities. When the bike has been fully put together, down to the signature head badge, the whole process has taken about a week, provided there are no major catastrophes.
Lorem ipsum fjasdklfs jfkdlsdjfdla jfdsakjfl fjkdajlf j fkldsajfls jfkdlsajfl kj kjfdlksaj fkldsjflkaj jfkldsaj kjkfdlsaj jkdfjdlasjf lksd
Lorem ipsum fjasdklfs jfkdlsdjfdla jfdsakjfl fjkdajlf j fkldsajfls jfkdlsajfl kj kjfdlksaj fkldsjflkaj jfkldsaj kjkfdlsaj jkdfjdlasjf lksd
Lorem ipsum fjasdklfs jfkdlsdjfdla jfdsakjfl fjkdajlf j fkldsajfls jfkdlsajfl kj kjfdlksaj fkldsjflkaj jfkldsaj kjkfdlsaj jkdfjdlasjf lksd
Lorem ipsum fjasdklfs jfkdlsdjfdla jfdsakjfl fjkdajlf j fkldsajfls jfkdlsajfl kj kjfdlksaj fkldsjflkaj jfkldsaj kjkfdlsaj jkdfjdlasjf lksd
Lorem ipsum fjasdklfs jfkdlsdjfdla jfdsakjfl fjkdajlf j fkldsajfls jfkdlsajfl kj kjfdlksaj fkldsjflkaj jfkldsaj kjkfdlsaj jkdfjdlasjf lksd
Lorem ipsum fjasdklfs jfkdlsdjfdla jfdsakjfl fjkdajlf j fkldsajfls jfkdlsajfl kj kjfdlksaj fkldsjflkaj jfkldsaj kjkfdlsaj jkdfjdlasjf lksd


Click the button to display the value of the button's first attribute value.
Note: In Internet Explorer 8 and earlier, the attributes property will return a collection of all possible attributes for the element, and will, in this example, display the name of a different attribute.


statsmodels Principal Component Analysis¶
Key ideas: Principal component analysis, world bank data, fertility
In this notebook, we use principal components analysis (PCA) to analyze the time series of fertility rates in 192 countries, using data obtained from the World Bank. The main goal is to understand how the trends in fertility over time differ from country to country. This is a slightly atypical illustration of PCA because the data are time series. Methods such as functional PCA have been developed for this setting, but since the fertility data are very smooth, there is no real disadvantage to using standard PCA in this case.
[1]:
%matplotlib inline
import matplotlib.pyplot as plt
import statsmodels.api as sm
from statsmodels.multivariate.pca import PCA
plt.rc("figure", figsize=(16, 8))
plt.rc("font", size=14)
The data can be obtained from the World Bank web site, but here we work with a slightly cleaned-up version of the data:
[2]:
data = sm.datasets.fertility.load_pandas().data
data.head()
[2]:
| Country Name | Country Code | Indicator Name | Indicator Code | 1960 | 1961 | 1962 | 1963 | 1964 | 1965 | ... | 2004 | 2005 | 2006 | 2007 | 2008 | 2009 | 2010 | 2011 | 2012 | 2013 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 0 | Aruba | ABW | Fertility rate, total (births per woman) | SP.DYN.TFRT.IN | 4.820 | 4.655 | 4.471 | 4.271 | 4.059 | 3.842 | ... | 1.786 | 1.769 | 1.754 | 1.739 | 1.726 | 1.713 | 1.701 | 1.690 | NaN | NaN |
| 1 | Andorra | AND | Fertility rate, total (births per woman) | SP.DYN.TFRT.IN | NaN | NaN | NaN | NaN | NaN | NaN | ... | NaN | NaN | 1.240 | 1.180 | 1.250 | 1.190 | 1.220 | NaN | NaN | NaN |
| 2 | Afghanistan | AFG | Fertility rate, total (births per woman) | SP.DYN.TFRT.IN | 7.671 | 7.671 | 7.671 | 7.671 | 7.671 | 7.671 | ... | 7.136 | 6.930 | 6.702 | 6.456 | 6.196 | 5.928 | 5.659 | 5.395 | NaN | NaN |
| 3 | Angola | AGO | Fertility rate, total (births per woman) | SP.DYN.TFRT.IN | 7.316 | 7.354 | 7.385 | 7.410 | 7.425 | 7.430 | ... | 6.704 | 6.657 | 6.598 | 6.523 | 6.434 | 6.331 | 6.218 | 6.099 | NaN | NaN |
| 4 | Albania | ALB | Fertility rate, total (births per woman) | SP.DYN.TFRT.IN | 6.186 | 6.076 | 5.956 | 5.833 | 5.711 | 5.594 | ... | 2.004 | 1.919 | 1.849 | 1.796 | 1.761 | 1.744 | 1.741 | 1.748 | NaN | NaN |
5 rows × 58 columns
Here we construct a DataFrame that contains only the numerical fertility rate data and set the index to the country names. We also drop all the countries with any missing data.
[3]:
columns = list(map(str, range(1960, 2012)))
data.set_index("Country Name", inplace=True)
dta = data[columns]
dta = dta.dropna()
dta.head()
[3]:
| 1960 | 1961 | 1962 | 1963 | 1964 | 1965 | 1966 | 1967 | 1968 | 1969 | ... | 2002 | 2003 | 2004 | 2005 | 2006 | 2007 | 2008 | 2009 | 2010 | 2011 | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Country Name | |||||||||||||||||||||
| Aruba | 4.820 | 4.655 | 4.471 | 4.271 | 4.059 | 3.842 | 3.625 | 3.417 | 3.226 | 3.054 | ... | 1.825 | 1.805 | 1.786 | 1.769 | 1.754 | 1.739 | 1.726 | 1.713 | 1.701 | 1.690 |
| Afghanistan | 7.671 | 7.671 | 7.671 | 7.671 | 7.671 | 7.671 | 7.671 | 7.671 | 7.671 | 7.671 | ... | 7.484 | 7.321 | 7.136 | 6.930 | 6.702 | 6.456 | 6.196 | 5.928 | 5.659 | 5.395 |
| Angola | 7.316 | 7.354 | 7.385 | 7.410 | 7.425 | 7.430 | 7.422 | 7.403 | 7.375 | 7.339 | ... | 6.778 | 6.743 | 6.704 | 6.657 | 6.598 | 6.523 | 6.434 | 6.331 | 6.218 | 6.099 |
| Albania | 6.186 | 6.076 | 5.956 | 5.833 | 5.711 | 5.594 | 5.483 | 5.376 | 5.268 | 5.160 | ... | 2.195 | 2.097 | 2.004 | 1.919 | 1.849 | 1.796 | 1.761 | 1.744 | 1.741 | 1.748 |
| United Arab Emirates | 6.928 | 6.910 | 6.893 | 6.877 | 6.861 | 6.841 | 6.816 | 6.783 | 6.738 | 6.679 | ... | 2.428 | 2.329 | 2.236 | 2.149 | 2.071 | 2.004 | 1.948 | 1.903 | 1.868 | 1.841 |
5 rows × 52 columns
There are two ways to use PCA to analyze a rectangular matrix: we can treat the rows as the “objects” and the columns as the “variables”, or vice-versa. Here we will treat the fertility measures as “variables” used to measure the countries as “objects”. Thus the goal will be to reduce the yearly fertility rate values to a small number of fertility rate “profiles” or “basis functions” that capture most of the variation over time in the different countries.
The mean trend is removed in PCA, but its worthwhile taking a look at it. It shows that fertility has dropped steadily over the time period covered in this dataset. Note that the mean is calculated using a country as the unit of analysis, ignoring population size. This is also true for the PC analysis conducted below. A more sophisticated analysis might weight the countries, say by population in 1980.
[4]:
ax = dta.mean().plot(grid=False)
ax.set_xlabel("Year", size=17)
ax.set_ylabel("Fertility rate", size=17)
ax.set_xlim(0, 51)
[4]:
(0.0, 51.0)
Next we perform the PCA:
[5]:
pca_model = PCA(dta.T, standardize=False, demean=True)
Based on the eigenvalues, we see that the first PC dominates, with perhaps a small amount of meaningful variation captured in the second and third PC’s.
[6]:
fig = pca_model.plot_scree(log_scale=False)
Next we will plot the PC factors. The dominant factor is monotonically increasing. Countries with a positive score on the first factor will increase faster (or decrease slower) compared to the mean shown above. Countries with a negative score on the first factor will decrease faster than the mean. The second factor is U-shaped with a positive peak at around 1985. Countries with a large positive score on the second factor will have lower than average fertilities at the beginning and end of the data range, but higher than average fertility in the middle of the range.
[7]:
fig, ax = plt.subplots(figsize=(8, 4))
lines = ax.plot(pca_model.factors.iloc[:, :3], lw=4, alpha=0.6)
ax.set_xticklabels(dta.columns.values[::10])
ax.set_xlim(0, 51)
ax.set_xlabel("Year", size=17)
fig.subplots_adjust(0.1, 0.1, 0.85, 0.9)
legend = fig.legend(lines, ["PC 1", "PC 2", "PC 3"], loc="center right")
legend.draw_frame(False)
/tmp/ipykernel_7045/427128218.py:3: UserWarning: FixedFormatter should only be used together with FixedLocator
ax.set_xticklabels(dta.columns.values[::10])
To better understand what is going on, we will plot the fertility trajectories for sets of countries with similar PC scores. The following convenience function produces such a plot.
[8]:
idx = pca_model.loadings.iloc[:, 0].argsort()
First we plot the five countries with the greatest scores on PC 1. These countries have a higher rate of fertility increase than the global mean (which is decreasing).
[9]:
def make_plot(labels):
fig, ax = plt.subplots(figsize=(9, 5))
ax = dta.loc[labels].T.plot(legend=False, grid=False, ax=ax)
dta.mean().plot(ax=ax, grid=False, label="Mean")
ax.set_xlim(0, 51)
fig.subplots_adjust(0.1, 0.1, 0.75, 0.9)
ax.set_xlabel("Year", size=17)
ax.set_ylabel("Fertility", size=17)
legend = ax.legend(
*ax.get_legend_handles_labels(), loc="center left", bbox_to_anchor=(1, 0.5)
)
legend.draw_frame(False)
[10]:
labels = dta.index[idx[-5:]]
make_plot(labels)
Here are the five countries with the greatest scores on factor 2. These are countries that reached peak fertility around 1980, later than much of the rest of the world, followed by a rapid decrease in fertility.
[11]:
idx = pca_model.loadings.iloc[:, 1].argsort()
make_plot(dta.index[idx[-5:]])
Finally we have the countries with the most negative scores on PC 2. These are the countries where the fertility rate declined much faster than the global mean during the 1960’s and 1970’s, then flattened out.
[12]:
make_plot(dta.index[idx[:5]])
We can also look at a scatterplot of the first two principal component scores. We see that the variation among countries is fairly continuous, except perhaps that the two countries with highest scores for PC 2 are somewhat separated from the other points. These countries, Oman and Yemen, are unique in having a sharp spike in fertility around 1980. No other country has such a spike. In contrast, the countries with high scores on PC 1 (that have continuously increasing fertility), are part of a continuum of variation.
[13]:
fig, ax = plt.subplots()
pca_model.loadings.plot.scatter(x="comp_00", y="comp_01", ax=ax)
ax.set_xlabel("PC 1", size=17)
ax.set_ylabel("PC 2", size=17)
dta.index[pca_model.loadings.iloc[:, 1] > 0.2].values
[13]:
array(['Oman', 'Yemen, Rep.'], dtype=object)


| Home | Trees | Indices | Help |
|
|---|
|
|
ViewClient is a ViewServer client.
If not running the ViewServer is started on the target device or emulator and then the port mapping is created.
No service is started.
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|
|||
|
device The MonkeyDevice device instance
|
|||
|
serialno The serial number of the device |
|||
|
adb The adb command |
|||
|
root The root node |
|||
|
viewsById The map containing all the Views indexed by their View.getUniqueId() |
|||
|
display The map containing the device's display properties: width, height and density |
|||
|
build The map containing the device's build properties: version.sdk, version.release |
|||
|
ro The map containing the device's ro properties: secure, debuggable |
|||
|
forceViewServerUse Force the use of ViewServer even if the conditions to use UiAutomator are satisfied |
|||
|
ignoreUiAutomatorKilled On some devices (i.e. |
|||
|
windows The list of windows as obtained by ViewClient.list() |
|||
|
views The list of Views represented as str obtained after
splitting it into lines after being received from the server.
|
|
Constructor
|
Connects to a device which serial number is obtained from the script
arguments if available or using the default regex If the connection is not successful the script exits.
|
Shows the View class, id and text if available. This function can be used as a transform function to ViewClient.traverse()
|
Shows the View class, id, text if available and unique id. This function can be used as a transform function to ViewClient.traverse()
|
Shows the View class, id, text if available and unique id. This function can be used as a transform function to ViewClient.traverse()
|
Shows the View class, id and text if available. This function can be used as a transform function to ViewClient.traverse()
|
Shows the View class, id and text if available. This function can be used as a transform function to ViewClient.traverse()
|
An alias for traverseShowClassIdAndText(view)
|
An alias for traverseShowClassIdTextAndUniqueId(view)
|
An alias for traverseShowClassIdTextAndContentDescription(view)
|
An alias for traverseShowClassIdTextAndCenter(view)
|
An alias for traverseShowClassIdTextPositionAndSize(view)
|
Sleeps for the specified number of seconds.
|
Checks whether the response received from the server is correct or raises and Exception.
|
Checks the response received from the ViewServer.
|
Sets self.views to the received value splitting it into lines.
|
Sets self.views to the received value parsing the received XML.
|
Splits the Unique IdsIt is very common to find The unique Ids are generated using the pattern
|
Parses the View tree contained in
|
Gets the root node of the
|
Traverses the The nodes are printed converting them to string but other
transformations can be specified by providing a method name as the
|
Dumps the window content. Sleep is useful to wait some time before obtaining the new content when something in the window has changed.
|
List the windows. Sleep is useful to wait some time before obtaining the new content when something in the window has changed. This also sets self.windows as the list of windows.
|
Finds the View with the specified viewId.
|
Finds the View or raise a ViewNotFoundException.
|
Finds the View or raise a ViewNotFoundException.
|
Finds the View or raise a ViewNotFoundException.
|
Deprecated: Use getViewsById instead. Returns the Views map. |
Returns the Views map. The keys are |
Write the View image to the specified filename in the specified format.
|
Calculates the distance between this tree and the tree passed as argument.
|
Finds the Hamming distance between two strings.
|
Find the Levenshtein distance between two Strings. Python version of Levenshtein distance method implemented in Java at http://www.java2s.com/Code/Java/Data-Type/FindtheLevenshteindistancebetweentwoStrings.htm. This is the number of changes needed to change one String into another, where each change is a single character modification (deletion, insertion or substitution). The previous implementation of the Levenshtein distance algorithm was from http://www.merriampark.com/ld.htm Chas Emerick has written an implementation in Java, which avoids an OutOfMemoryError which can occur when my Java implementation is used with very large strings. This implementation of the Levenshtein distance algorithm is from http://www.merriampark.com/ldjava.htm: StringUtils.getLevenshteinDistance(null, *) = IllegalArgumentException StringUtils.getLevenshteinDistance(*, null) = IllegalArgumentException StringUtils.getLevenshteinDistance("","") = 0 StringUtils.getLevenshteinDistance("","a") = 1 StringUtils.getLevenshteinDistance("aaapppp", "") = 7 StringUtils.getLevenshteinDistance("frog", "fog") = 1 StringUtils.getLevenshteinDistance("fly", "ant") = 3 StringUtils.getLevenshteinDistance("elephant", "hippo") = 7 StringUtils.getLevenshteinDistance("hippo", "elephant") = 7 StringUtils.getLevenshteinDistance("hippo", "zzzzzzzz") = 8 StringUtils.getLevenshteinDistance("hello", "hallo") = 1
|
|
ignoreUiAutomatorKilledOn some devices (i.e. Nexus 7 running 4.2.2) uiautomator is killed
just after generating the dump file. In many cases the file is already
complete so we can ask to ignore the 'Killed' message by setting Changes in v2.3.21 that uses |
viewsThe list of Views represented as |
| Home | Trees | Indices | Help |
|
|---|
| Generated by Epydoc 3.0.1 on Thu May 22 01:36:01 2014 | http://epydoc.sourceforge.net |


See: Description
| Interface | Description |
|---|---|
| JavaCodeHandler |
This interface defines the Java Code Handler.
|
| JavaCodeModel.JType |
Java Type interface.
|
| JavadocHandler |
Defines a consumer for Javadoc parsing events.
|
| JavaQueryModel |
Defines the query model for the Java language.
|
| Class | Description |
|---|---|
| JAsset |
Defines a Java asset.
|
| JAttribute |
Represents a Java attribute.
|
| JavaCodeHandlerDebugImpl |
A
CodeHandler implementation used to perform debugging. |
| JavaCodeHandlerImpl |
The
JavaCodeHandler
default implementation. |
| JavaCodeModel |
This abstract class describes a Java Code Model.
|
| JavaCodeModel.ArrayType |
The array type.
|
| JavaCodeModel.ExceptionType |
The Exception Type.
|
| JavaCodeModel.InterfaceType |
The interface type.
|
| JavaCodeModel.JPrimitiveType |
Java primitive Type base class.
|
| JavaCodeModel.ObjectType |
The Object type.
|
| JavaCodeModel.StructuredType |
Base of all structured types.
|
| JavaCodeModel.TYPE_BOOL | |
| JavaCodeModel.TYPE_BYTE | |
| JavaCodeModel.TYPE_CHAR | |
| JavaCodeModel.TYPE_DOUBLE | |
| JavaCodeModel.TYPE_FLOAT | |
| JavaCodeModel.TYPE_INT | |
| JavaCodeModel.TYPE_LONG | |
| JavaCodeModel.TYPE_SHORT | |
| JavaCodeModel.TYPE_VOID | |
| JavaCoderFactory |
The Java language Coder Factory.
|
| JavaOntology |
Defines the Java ontology.
|
| JavaQueryModelImpl |
Default implementation of
JavaQueryModel . |
| JBase |
Defines the base class for any code entity.
|
| JClass |
Represents a Java class.
|
| JContainer |
Represents every Java entity able to contain other entities.
|
| JEnumeration |
Represents a Java enumeration.
|
| JInterface |
Represents a Java interface.
|
| JMethod |
Represents a Java method.
|
| JModifiable |
Represents any Java entity class with visibility and modifiers.
|
| JObject |
The base class for both
JInterface
and JClass , and defines some methods useful to access
classes, interfaces and common entities. |
| JPackage |
Represents a Java package.
|
| JSignature |
Represents a Java method signature.
|
| Enum | Description |
|---|---|
| JavaCodeModel.JModifier |
Defines the Java modifiers.
|
| JavaCodeModel.JVisibility |
Defines the visibility level of an entity.
|
This package provides the model for the Java profile.
Copyright © 2017 Michele Mostarda. All Rights Reserved.


Your quote has been saved with number XXXX
| Options | 10 Days | Semiannual | Annual |
|---|---|---|---|
| Liability View Coverage |
$ 50.20 View Detail |
$ 66.86 View Detail |
$ 105.47 View Detail |
| Full Coverage View Coverage |
$ 110.01 View Detail |
$ 235.24 View Detail |
$ 309.02 View Detail |
| Premium Full Coverage View Coverage |
$ 170.68 View Detail |
$ 268.92 View Detail |
$ 400.91 View Detail |


◀
▶
Funky shaders (For reference)
Color wave shift
Sampling: Colors
Color wave shift
Sampling: Distortion
Displacement
Sampling: Displacement
Patterns
Case study: Patterns
Pinch and Bulge
Kaleidoscope
Quasicrystal
Quasycrystal case study
Noise
Noise construction


Chapter 4 Next Steps
4.1 About this chapter
- Questions
- How can I filter out the ‘significant’ genes?
- How can I find the functions of these genes?
- Objectives
- Filter the genes by p value
- Find the gene annotations on an external service
- Keypoints
- The p value we need must be corrected for the large number of genes
In this chapter we’ll look at how to take our results table and get the significantly differentially expressed genes out of it.
4.2 The results data frame
The object we created in the previous chapter results_data
is already in the general format we need. Im going to load a version with different gene names (from Magnaporthe, not Arabidopsis) so we can work on a more familiar genome.
## gene baseMean log2FoldChange lfcSE stat pvalue
## 1 MGG_00865 1022.3995 0.6385565 0.7527580 0.8482893 0.3962769
## 2 MGG_08134 1522.9579 0.3549260 0.7857086 0.4517273 0.6514655
## 3 MGG_01588 946.5248 0.6718950 0.7428144 0.9045260 0.3657165
## 4 MGG_13806 2230.1049 -0.5918810 0.6036652 -0.9804789 0.3268498
## 5 MGG_06121 1539.4032 -0.4202588 0.5376360 -0.7816790 0.4344032
## 6 MGG_06504 1384.9674 -0.4856173 0.6907157 -0.7030640 0.4820159
## padj
## 1 0.7472062
## 2 0.7965762
## 3 0.7472062
## 4 0.7472062
## 5 0.7551582
## 6 0.7551582
4.2.1 Which p value?
Note that two columns in this data.frame have p value information in them - pvalue
and padj
. Which is the correct one? We need the adjusted p value in padj
.
The reason for this is that a separate p value was calculated in a separate test for each gene. As p values have a built in error expectation (IE p = 0.05 means the test will be wrong 5 percent of the time on average) then repeating the test means that using a gene level p value means we get lots of errors. So we need a whole gene set p value rather than a per gene value. Hence DESeq
adjusts the p value for the whole set of genes.
4.3 Filtering rows with significant p values
To filter the rows in the data frame we can use tidyverse
tools like dplyr
(which we study in a separate training course). Let’s keep rows from the results_data
data frame with a padj
lower than 0.05
## gene baseMean log2FoldChange lfcSE stat pvalue padj
## 1 MGG_12738 552.4170 -1.2700540 1.1960414 1.061881 0.005 0.030
## 2 MGG_01482 1912.4502 1.1010845 0.8063151 1.365576 0.005 0.004
## 3 MGG_17878 988.8704 0.9095213 0.9142498 0.994828 0.002 0.010
The filter()
function works by taking the dataframe and the condition and column to filter with.
4.3.1 Filtering UP and DOWN genes
An elaboration of this is to find the up or down genes. To do this we need to build a filter on the log2FoldChange
column. As the fold changes are encoded in a log scale, up regulated genes will have a positive value, down regulated genes will have a negative value
## gene baseMean log2FoldChange lfcSE stat pvalue padj
## 1 MGG_01482 1912.4502 1.1010845 0.8063151 1.365576 0.005 0.004
## 2 MGG_17878 988.8704 0.9095213 0.9142498 0.994828 0.002 0.010
## gene baseMean log2FoldChange lfcSE stat pvalue padj
## 1 MGG_12738 552.417 -1.270054 1.196041 1.061881 0.005 0.03
Note that if you want to find values that are two fold up or down regulated, then you’ll need to change the log2FoldChange
values to 1
and -1
(as log2(2) = 1
and log2(0.5) = -1
).
You can export each of these tables to files with write.csv()
as previously.
4.4 Finding gene annotations
A common question is ‘which pathways and functional categories do my genes belong to?’. Answering this requires quite an involved process, and doing it entirely in R is out of scope for this ‘minimal’ RNAseq tutorial. Instead of avoiding the question completely, we’ll look at how to achieve a basic annotation using webtools. Specifically, the Ensembl BioMart service.
4.4.1 BioMart
BioMart is a data warehouse for genomic information that can be queried through a web interface. Not all genome projects provide such a service, but the ones on Ensembl generally do. We’ll work with the Magnaporthe one here, available at https://fungi.ensembl.org/Magnaporthe_oryzae/Info/Index
To access it we need to click BioMart
from the top menu, and be patient, it can take a little while to load.
Then we need to follow this procedure to get a gene list annotated
- From the
Choose Database
drop-down selectEnsembl Fungi Genes
- From the
Choose Dataset
drop down selectMagnaporthe oryzae genes (MG8)
- Select the
Attributes
page and on theExternal
tab tickGO Term Name
,GO Term Definition
andKEGG Pathway and Enzyme ID
. These attributes are the things you will retrieve from the BioMart. - Select the
Filters
page and click on theExternal
tab, paste in the gene IDs of interest into the box or upload a file. - Click
Results
button at the top
After a wait, the screen should fill with the annotations that you asked for. You can save this to a file using the Export
options at the top.
This is all you need to make an annotated gene list.
4.5 Further Questions
Of course, this isn’t all you might want to do with your RNAseq data and gene lists. We’ve achieved our overall goal of getting a minimal RNAseq analysis done. What happens next will be quite different for every experiment. For example, you might want to look at seeing whether a GO Term or enzymatic pathway is enriched. Pretty much everything will be a separate analysis in itself and will require some design and planning. Please feel free to talk to the bioinformatics team when you find yourself at this stage, we’ll be extremely happy to work with you!


public abstract class NumberFormat extends Format
NumberFormat
is the abstract base class for all number
formats. This class provides the interface for formatting and parsing
numbers. NumberFormat
also provides methods for determining
which locales have number formats, and what their names are.
NumberFormat
helps you to format and parse numbers for any locale.
Your code can be completely independent of the locale conventions for
decimal points, thousands-separators, or even the particular decimal
digits used, or whether the number format is even decimal.
To format a number for the current Locale, use one of the factory class methods:
If you are formatting multiple numbers, it is more efficient to get the format and use it multiple times so that the system doesn't have to fetch the information about the local language and country conventions multiple times.myString = NumberFormat.getInstance().format(myNumber);
To format a number for a different Locale, specify it in the call toNumberFormat nf = NumberFormat.getInstance(); for (int i = 0; i < myNumber.length; ++i) { output.println(nf.format(myNumber[i]) + "; "); }
getInstance
.
You can also use aNumberFormat nf = NumberFormat.getInstance(Locale.FRENCH);
NumberFormat
to parse numbers:
UsemyNumber = nf.parse(myString);
getInstance
or getNumberInstance
to get the
normal number format. Use getIntegerInstance
to get an
integer number format. Use getCurrencyInstance
to get the
currency number format. And use getPercentInstance
to get a
format for displaying percentages. With this format, a fraction like
0.53 is displayed as 53%.
You can also control the display of numbers with such methods as
setMinimumFractionDigits
.
If you want even more control over the format or parsing,
or want to give your users more control,
you can try casting the NumberFormat
you get from the factory methods
to a DecimalFormat
. This will work for the vast majority
of locales; just remember to put it in a try
block in case you
encounter an unusual one.
NumberFormat and DecimalFormat are designed such that some controls work for formatting and others work for parsing. The following is the detailed description for each these control methods,
setParseIntegerOnly : only affects parsing, e.g. if true, "3456.78" → 3456 (and leaves the parse position just after index 6) if false, "3456.78" → 3456.78 (and leaves the parse position just after index 8) This is independent of formatting. If you want to not show a decimal point where there might be no digits after the decimal point, use setDecimalSeparatorAlwaysShown.
setDecimalSeparatorAlwaysShown : only affects formatting, and only where there might be no digits after the decimal point, such as with a pattern like "#,##0.##", e.g., if true, 3456.00 → "3,456." if false, 3456.00 → "3456" This is independent of parsing. If you want parsing to stop at the decimal point, use setParseIntegerOnly.
You can also use forms of the parse
and format
methods with ParsePosition
and FieldPosition
to
allow you to:
FieldPosition
in your format call, with
field
= INTEGER_FIELD
. On output,
getEndIndex
will be set to the offset between the
last character of the integer and the decimal. Add
(desiredSpaceCount - getEndIndex) spaces at the front of the string.
getEndIndex
.
Then move the pen by
(desiredPixelWidth - widthToAlignmentPoint) before drawing the text.
It also works where there is no decimal, but possibly additional
characters at the end, e.g., with parentheses in negative
numbers: "(12)" for -12.
Number formats are generally not synchronized. It is recommended to create separate format instances for each thread. If multiple threads access a format concurrently, it must be synchronized externally.
DecimalFormat
,
ChoiceFormat
,
Serialized Form| Modifier and Type | Class and Description |
|---|---|
static class |
NumberFormat.Field
Defines constants that are used as attribute keys in the
AttributedCharacterIterator returned
from NumberFormat.formatToCharacterIterator and as
field identifiers in FieldPosition . |
| Modifier and Type | Field and Description |
|---|---|
static int |
FRACTION_FIELD
Field constant used to construct a FieldPosition object.
|
static int |
INTEGER_FIELD
Field constant used to construct a FieldPosition object.
|
| Modifier | Constructor and Description |
|---|---|
protected |
NumberFormat()
Sole constructor.
|
| Modifier and Type | Method and Description |
|---|---|
Object |
clone()
Overrides Cloneable.
|
boolean |
equals(Object obj)
Overrides equals.
|
String |
format(double number)
Specialization of format.
|
abstract StringBuffer |
format(double number,
StringBuffer toAppendTo,
FieldPosition pos)
Specialization of format.
|
String |
format(long number)
Specialization of format.
|
abstract StringBuffer |
format(long number,
StringBuffer toAppendTo,
FieldPosition pos)
Specialization of format.
|
StringBuffer |
format(Object number,
StringBuffer toAppendTo,
FieldPosition pos)
Formats a number and appends the resulting text to the given string
buffer.
|
static Locale[] |
getAvailableLocales()
Returns an array of all locales for which the
get*Instance methods of this class can return
localized instances. |
Currency |
getCurrency()
Gets the currency used by this number format when formatting
currency values.
|
static NumberFormat |
getCurrencyInstance()
Returns a currency format for the current default
FORMAT locale. |
static NumberFormat |
getCurrencyInstance(Locale inLocale)
Returns a currency format for the specified locale.
|
static NumberFormat |
getInstance()
Returns a general-purpose number format for the current default
FORMAT locale. |
static NumberFormat |
getInstance(Locale inLocale)
Returns a general-purpose number format for the specified locale.
|
static NumberFormat |
getIntegerInstance()
Returns an integer number format for the current default
FORMAT locale. |
static NumberFormat |
getIntegerInstance(Locale inLocale)
Returns an integer number format for the specified locale.
|
int |
getMaximumFractionDigits()
Returns the maximum number of digits allowed in the fraction portion of a
number.
|
int |
getMaximumIntegerDigits()
Returns the maximum number of digits allowed in the integer portion of a
number.
|
int |
getMinimumFractionDigits()
Returns the minimum number of digits allowed in the fraction portion of a
number.
|
int |
getMinimumIntegerDigits()
Returns the minimum number of digits allowed in the integer portion of a
number.
|
static NumberFormat |
getNumberInstance()
Returns a general-purpose number format for the current default
FORMAT locale. |
static NumberFormat |
getNumberInstance(Locale inLocale)
Returns a general-purpose number format for the specified locale.
|
static NumberFormat |
getPercentInstance()
Returns a percentage format for the current default
FORMAT locale. |
static NumberFormat |
getPercentInstance(Locale inLocale)
Returns a percentage format for the specified locale.
|
RoundingMode |
getRoundingMode()
Gets the
RoundingMode used in this NumberFormat. |
int |
hashCode()
Overrides hashCode.
|
boolean |
isGroupingUsed()
Returns true if grouping is used in this format.
|
boolean |
isParseIntegerOnly()
Returns true if this format will parse numbers as integers only.
|
Number |
parse(String source)
Parses text from the beginning of the given string to produce a number.
|
abstract Number |
parse(String source,
ParsePosition parsePosition)
Returns a Long if possible (e.g., within the range [Long.MIN_VALUE,
Long.MAX_VALUE] and with no decimals), otherwise a Double.
|
Object |
parseObject(String source,
ParsePosition pos)
Parses text from a string to produce a
Number . |
void |
setCurrency(Currency currency)
Sets the currency used by this number format when formatting
currency values.
|
void |
setGroupingUsed(boolean newValue)
Set whether or not grouping will be used in this format.
|
void |
setMaximumFractionDigits(int newValue)
Sets the maximum number of digits allowed in the fraction portion of a
number.
|
void |
setMaximumIntegerDigits(int newValue)
Sets the maximum number of digits allowed in the integer portion of a
number.
|
void |
setMinimumFractionDigits(int newValue)
Sets the minimum number of digits allowed in the fraction portion of a
number.
|
void |
setMinimumIntegerDigits(int newValue)
Sets the minimum number of digits allowed in the integer portion of a
number.
|
void |
setParseIntegerOnly(boolean value)
Sets whether or not numbers should be parsed as integers only.
|
void |
setRoundingMode(RoundingMode roundingMode)
Sets the
RoundingMode used in this NumberFormat. |
format, formatToCharacterIterator, parseObject
public static final int INTEGER_FIELD
FieldPosition
,
Constant Field Valuespublic static final int FRACTION_FIELD
FieldPosition
,
Constant Field Valuesprotected NumberFormat()
public StringBuffer format(Object number, StringBuffer toAppendTo, FieldPosition pos)
Number
.
This implementation extracts the number's value using
Number.longValue()
for all integral type values that
can be converted to long
without loss of information,
including BigInteger
values with a
bit length
of less than 64,
and Number.doubleValue()
for all other types. It
then calls
format(long,java.lang.StringBuffer,java.text.FieldPosition)
or format(double,java.lang.StringBuffer,java.text.FieldPosition)
.
This may result in loss of magnitude information and precision for
BigInteger
and BigDecimal
values.
format
in class Format
number
- the number to formattoAppendTo
- the StringBuffer
to which the formatted
text is to be appendedpos
- On input: an alignment field, if desired.
On output: the offsets of the alignment field.toAppendTo
IllegalArgumentException
- if number
is
null or not an instance of Number
.NullPointerException
- if toAppendTo
or
pos
is nullArithmeticException
- if rounding is needed with rounding
mode being set to RoundingMode.UNNECESSARYFieldPosition
public final Object parseObject(String source, ParsePosition pos)
Number
.
The method attempts to parse text starting at the index given by
pos
.
If parsing succeeds, then the index of pos
is updated
to the index after the last character used (parsing does not necessarily
use all characters up to the end of the string), and the parsed
number is returned. The updated pos
can be used to
indicate the starting point for the next call to this method.
If an error occurs, then the index of pos
is not
changed, the error index of pos
is set to the index of
the character where the error occurred, and null is returned.
See the parse(String, ParsePosition)
method for more information
on number parsing.
parseObject
in class Format
source
- A String
, part of which should be parsed.pos
- A ParsePosition
object with index and error
index information as described above.Number
parsed from the string. In case of
error, returns null.NullPointerException
- if pos
is null.public final String format(double number)
number
- the double number to formatArithmeticException
- if rounding is needed with rounding
mode being set to RoundingMode.UNNECESSARYFormat.format(java.lang.Object)
public final String format(long number)
number
- the long number to formatArithmeticException
- if rounding is needed with rounding
mode being set to RoundingMode.UNNECESSARYFormat.format(java.lang.Object)
public abstract StringBuffer format(double number, StringBuffer toAppendTo, FieldPosition pos)
number
- the double number to formattoAppendTo
- the StringBuffer to which the formatted text is to be
appendedpos
- the field positionArithmeticException
- if rounding is needed with rounding
mode being set to RoundingMode.UNNECESSARYFormat.format(java.lang.Object)
public abstract StringBuffer format(long number, StringBuffer toAppendTo, FieldPosition pos)
number
- the long number to formattoAppendTo
- the StringBuffer to which the formatted text is to be
appendedpos
- the field positionArithmeticException
- if rounding is needed with rounding
mode being set to RoundingMode.UNNECESSARYFormat.format(java.lang.Object)
public abstract Number parse(String source, ParsePosition parsePosition)
source
- the String to parseparsePosition
- the parse positionisParseIntegerOnly()
,
Format.parseObject(java.lang.String, java.text.ParsePosition)
public Number parse(String source) throws ParseException
See the parse(String, ParsePosition)
method for more information
on number parsing.
source
- A String
whose beginning should be parsed.Number
parsed from the string.ParseException
- if the beginning of the specified string
cannot be parsed.public boolean isParseIntegerOnly()
true
if numbers should be parsed as integers only;
false
otherwisepublic void setParseIntegerOnly(boolean value)
value
- true
if numbers should be parsed as integers only;
false
otherwiseisParseIntegerOnly()
public static final NumberFormat getInstance()
FORMAT
locale.
This is the same as calling
getNumberInstance()
.NumberFormat
instance for general-purpose number
formattingpublic static NumberFormat getInstance(Locale inLocale)
getNumberInstance(inLocale)
.inLocale
- the desired localeNumberFormat
instance for general-purpose number
formattingpublic static final NumberFormat getNumberInstance()
FORMAT
locale.
This is equivalent to calling
getNumberInstance(Locale.getDefault(Locale.Category.FORMAT))
.
NumberFormat
instance for general-purpose number
formattingLocale.getDefault(java.util.Locale.Category)
,
Locale.Category.FORMAT
public static NumberFormat getNumberInstance(Locale inLocale)
inLocale
- the desired localeNumberFormat
instance for general-purpose number
formattingpublic static final NumberFormat getIntegerInstance()
FORMAT
locale. The
returned number format is configured to round floating point numbers
to the nearest integer using half-even rounding (see RoundingMode.HALF_EVEN
) for formatting,
and to parse only the integer part of an input string (see isParseIntegerOnly
).
This is equivalent to calling
getIntegerInstance(Locale.getDefault(Locale.Category.FORMAT))
.
getRoundingMode()
,
Locale.getDefault(java.util.Locale.Category)
,
Locale.Category.FORMAT
public static NumberFormat getIntegerInstance(Locale inLocale)
RoundingMode.HALF_EVEN
) for formatting,
and to parse only the integer part of an input string (see isParseIntegerOnly
).inLocale
- the desired localegetRoundingMode()
public static final NumberFormat getCurrencyInstance()
FORMAT
locale.
This is equivalent to calling
getCurrencyInstance(Locale.getDefault(Locale.Category.FORMAT))
.
NumberFormat
instance for currency formattingLocale.getDefault(java.util.Locale.Category)
,
Locale.Category.FORMAT
public static NumberFormat getCurrencyInstance(Locale inLocale)
inLocale
- the desired localeNumberFormat
instance for currency formattingpublic static final NumberFormat getPercentInstance()
FORMAT
locale.
This is equivalent to calling
getPercentInstance(Locale.getDefault(Locale.Category.FORMAT))
.
NumberFormat
instance for percentage formattingLocale.getDefault(java.util.Locale.Category)
,
Locale.Category.FORMAT
public static NumberFormat getPercentInstance(Locale inLocale)
inLocale
- the desired localeNumberFormat
instance for percentage formattingpublic static Locale[] getAvailableLocales()
get*Instance
methods of this class can return
localized instances.
The returned array represents the union of locales supported by the Java
runtime and by installed
NumberFormatProvider
implementations.
It must contain at least a Locale
instance equal to
Locale.US
.NumberFormat
instances are available.public int hashCode()
hashCode
in class Object
Object.equals(java.lang.Object)
,
System.identityHashCode(java.lang.Object)
public boolean equals(Object obj)
equals
in class Object
obj
- the reference object with which to compare.true
if this object is the same as the obj
argument; false
otherwise.Object.hashCode()
,
HashMap
public Object clone()
public boolean isGroupingUsed()
true
if grouping is used;
false
otherwisesetGroupingUsed(boolean)
public void setGroupingUsed(boolean newValue)
newValue
- true
if grouping is used;
false
otherwiseisGroupingUsed()
public int getMaximumIntegerDigits()
setMaximumIntegerDigits(int)
public void setMaximumIntegerDigits(int newValue)
newValue
- the maximum number of integer digits to be shown; if
less than zero, then zero is used. The concrete subclass may enforce an
upper limit to this value appropriate to the numeric type being formatted.getMaximumIntegerDigits()
public int getMinimumIntegerDigits()
setMinimumIntegerDigits(int)
public void setMinimumIntegerDigits(int newValue)
newValue
- the minimum number of integer digits to be shown; if
less than zero, then zero is used. The concrete subclass may enforce an
upper limit to this value appropriate to the numeric type being formatted.getMinimumIntegerDigits()
public int getMaximumFractionDigits()
setMaximumFractionDigits(int)
public void setMaximumFractionDigits(int newValue)
newValue
- the maximum number of fraction digits to be shown; if
less than zero, then zero is used. The concrete subclass may enforce an
upper limit to this value appropriate to the numeric type being formatted.getMaximumFractionDigits()
public int getMinimumFractionDigits()
setMinimumFractionDigits(int)
public void setMinimumFractionDigits(int newValue)
newValue
- the minimum number of fraction digits to be shown; if
less than zero, then zero is used. The concrete subclass may enforce an
upper limit to this value appropriate to the numeric type being formatted.getMinimumFractionDigits()
public Currency getCurrency()
setCurrency
.
The default implementation throws
UnsupportedOperationException
.
null
UnsupportedOperationException
- if the number format class
doesn't implement currency formattingpublic void setCurrency(Currency currency)
The default implementation throws
UnsupportedOperationException
.
currency
- the new currency to be used by this number formatUnsupportedOperationException
- if the number format class
doesn't implement currency formattingNullPointerException
- if currency
is nullpublic RoundingMode getRoundingMode()
RoundingMode
used in this NumberFormat.
The default implementation of this method in NumberFormat
always throws UnsupportedOperationException
.
Subclasses which handle different rounding modes should override
this method.RoundingMode
used for this NumberFormat.UnsupportedOperationException
- The default implementation
always throws this exceptionsetRoundingMode(RoundingMode)
public void setRoundingMode(RoundingMode roundingMode)
RoundingMode
used in this NumberFormat.
The default implementation of this method in NumberFormat always
throws UnsupportedOperationException
.
Subclasses which handle different rounding modes should override
this method.roundingMode
- The RoundingMode
to be usedUnsupportedOperationException
- The default implementation
always throws this exceptionNullPointerException
- if roundingMode
is nullgetRoundingMode()
Dracula Javadoc Sample, Made with Allan Im.


We assist educators at all levels to introduce open source mapping and OpenStreetMap in the classroom
The Educational Portal is where educators can share educational exercises, projects and lesson plans with one another and obtain contact information for educators around the world.
We offer educator training in person and remotely and announce those training opportunities and other similar educator training opportunities through our calendar of events.
We have curated various OpenStreetMap and other open mapping resources that we have identified as helping educators solve issues and roadblocks either themselves or their students commonly encounter.