Saturday, March 31, 2018

website design - Most intuitive way to offer manual sorting?



all. I'm designing an online form builder (think Forms in Google Docs / Spreadsheets). The functionality is complete, but I'm not happy with the sorting capabilities. Everyone that I have done usability tests with (five or so, including myself) didn't realize that the items could be sorted.


This leaves me with a question: Is there a best practice / most intuitive way to present a list to be manually sorted?


As a few examples:


Google Docs / Spreadsheets / Forms:


Google's method is to have almost no indication that the items in their Forms can be sorted. They use cursor: move; in their CSS to indicate that it is moveable, but nothing more.


jQuery UI:



jQueryUI's Sortable is fairly similar. Almost no interface, save for a double arrow on the left hand side. This is what I am currently using which is not being recognized by users.


Up/down buttons:


I can't think of any examples, but I have seen sorting using [+] and [-] buttons. This seemed to be easy for users to pick up on, but meant the possibility of requiring n-1 clicks to get from the bottom to the top.



Answer



Displaying a "grip" pattern at one side of the item, combined with the "move" cursor is fairly obvious to moderately savvy users.


Up/Down arrows are an option too, but that obviously falls short of powerful when you can only move one position at a time.


factor models - Question about Fama Macbeth Regression (Confusion about paper)



I'm reading this paper Zura Kakushadze: 4-Factor Model for Overnight Returns https://arxiv.org/pdf/1410.5513.pdf and I am slightly confused about the methodology of the regressions.


It says it uses Fama MacBeth to use the residuals for a mean reversion strategy. Now, I am also somewhat confused about Fama MacBeth as well.


From what I understand, first you run cross sectional regressions to get your betas, then you run a time series regression to get the risk premiums.


So, if we had say four factors, and let's say we had 10 years of daily data (2,520 days) and let's say we had 5,000 stocks. So if my understanding is clear, first we would use the cross sectional regression to estimate 4*5,000=20,000 betas? And then you get the risk premia, which you would have a value for each day for each factor (2,520 per factor)?


Given I understand that correctly (PLEASE tell me if I am mistaken), I am confused what this paper is doing. It looks like it calculates the betas directly. But it's saying it is running the cross sectional regressions to get the factor returns. Is that the same as the risk premium?


Any clarification would be much appreciated. I am trying to replicate this but am having major confusion.




website design - Adding "Select..." as first option (placeholder) of dropdown list


Would it be considered a good practice to add the word "Select..." as the first option of a dropdown list? I think it's redundant and not at all necessary and what is in the dropdown list should be only a list of options that are available, not instructions.


Am I wrong?


Edit: Just to make it clear, by first option I don't mean DEFAULT. Most of the answers are about default option being preselected etc. That's not what this question is about. It's about displaying the combobox with "Select..." or other instructional text so people know they have to select something in there.



Answer



A dropdown list (or combobox) should already be a clear indication that you need to select an item from there, so wasting the first item by telling someone this is redundant and a poor idea.


The only times that I would recommend having some other text in the dropdown are:



  1. when it is not essential to select an item


  2. when you want effectively to select all items.


Here are some examples:


enter image description here
enter image description here
enter image description here


business - How to use value-based pricing for design projects?


tl;dr What is the best way to use value-based fees for design projects? What would the "value" be?


I see that a lot of designers use time-based pricing (hourly, daily, etc.) Time-based pricing is horrible, for the following reasons:



  1. There's a conflict of interest between you and the client. The longer the work takes, the more you earn and the more the client loses. So it's unethical.

  2. When you set an hourly fee, you set a limit to what you can earn, as you have limited time. Say you set 100,000$ as your goal for the year, who knows you can't earn double, or triple that?

  3. It's difficult to justify a price after you are done. What if you finish the project, and it takes you much more than you calculated, and the client refuses to pay?


Second option, putting fixed prices to specific tasks is better, but still not really good, for the following reasons:




  1. When you set a fixed price to tasks like business card design, website design, etc., it might be completely different from one client to another, and you will still be charging the same.

  2. It's difficult to justify costs to clients when you show your services as commodities.


Best way to price things, most of the time, is to use value-based pricing, because:



  1. You will be able to justify much higher fees to the client, if you show them the tangible benefits they will be getting.

  2. It's ethical, as you base your fees on the value you are offering to the client. If they are expected to earn 10$ from your services, you can charge them 1$, and they will be happy with an ROI of 1 to 10.

  3. Sky's the limit.



But I'm wondering what the best way is when you are using value-based fees for design work. For example, when you are doing consulting, you can see that a 10% improvement in "Operation A" can offer the client 1 million dollars in revenue. So you can charge the client 100,000$.


With design work, the ROI is not tangible enough. How would you justify your fees to the client, and what would be the "values" you are going to be offering?


What exactly do I mean with "value-based fees"? I think "value-based fees" have a different meaning in design community. What I mean is this: There's a school of thought saying "your fees should be based on the tangible and intangible values the client will get." A tangible value could be direct increase in revenue. An intangible value could be offering a service no one else can offer, or increasing employee morale. But I'm having a difficult time thinking of values the client will get in design projects.


For example, one thing I can think of is showing the client how much a client with professional logos earn more. Let's say there's a research saying that "companies that have professional logos earn 10% more". You can use that research to say that the client will get an average of 10% experience in revenue and you can get 10% off of that. Though the difficult thing is, design is pretty much subjective. So what is a "professional logo"? Or which logo is better? All these things make value based pricing difficult, as it's easier to use value based pricing with tangible things, which design seems not to be.



Answer



Free-market theory defines the value of a product or service as the amount of money someone else is willing to pay for it. In other words, the value of your service is how much a client is willing to pay for it, and your ability to justify your fee is itself a determination of your value.


I understand your definition, that the value of your service should be based on the expected revenue increase it would generate for the client. However, the amount of research you would have to do in order to make such a quote would usually outweigh the project itself.


Instead, if you're uncomfortable with a per-hour rate, use a fee-per-service rate but offer multiple options presented in terms of their value to the client.


In other words, you'd offer a basic quote for a simple logo design, and then progressively higher quotes for extra research (an assessment of the competition's branding strategy to ensure the logo is unique, or user testing ) or extra design (multiple logo options, multiple sizes/styles e.g monochrome or simplified versions).


You then present the client with a "menu" of options, and let them decide whether they want to pay for the higher-value work. Make it clear what each option entails -- i.e., if they only pay for a basic logo design, and then don't like it, there will be fees for a re-design.



The quotes for each value level would be based on your expectation of how much time it should take, but can also be adjusted if you think you can offer a service your competition can't, regardless of whether it is time-consuming or not.


How to have a custom Default Swatch Library in Illustrator


Is there a way to have my custom Swatch Library open up in the top left corner, rather than the default library?


I have colors and spot colors I use in almost all my files. I would like to have them, and a true 100% CMYK in my default swatch library.




Friday, March 30, 2018

gimp - DPI Vs. PPI Vs. Image dimension, what should be taken to consideration?


I've been really facing this problem and I have found a similar link, that does not really address the problem. First of all, I'd like to mention that I use blender and GIMP for most graphics that I design and please read all the way through.


Blender has export option that are only available in dimensions (e.g. 1920 X 1860), and no matter how big we set this up and check the PPI in GIMP(or photoshop, knowing GIMP does only handle 8 - bit images), the PPI is always 72.009.



On employment site, we are requested to provide information if we are ready to supply to our clients a high resolution image atleast a 300DPI, and the dimension is not mentioned.


Furthermore, I have visited many websites and confirmed that the terms DPI and PPI are used quite interchangeably.


Even though we can set the image PPI in GIMP from 72.009 to 300 as easily as image -> scale -> 72 to 300, there is no realtime feedback in the screen to know that the image PPI has been changed.


So, the problem is around what should the output would be, would it be a higher dimensioned image, a higher PPI image or a higher DPI image that would really mean HIGH RESOLUTION?
How can we really set it to a standard 300DPI image, on the aforementioned link, I don't really know if it is not to be optimized for printing.



Answer



Image size (in pixels), print size (in inches), and print definition (in PPI) are completely related by a simple formula:


print_size = size_in_pixels / print_definition

This formula can also be expressed as:



size_in_pixels = print_size * print_definition

or


print_definition = size_in_pixels / print_size

But it should be clear that you can only change two terms at the same time, the third term will completely determined by the other two. For instance a 3000x1500 pixels image printed at 300DPI yields a 10"x5" image.


When you create an image in Gimp, the image creation dialog lets you give the image size in inches (just change the units), and specify a print definition. Gimp will compute the required size in pixels for you.


Good quality printing requires at least 300PPI.


Print definition, as associated to the image, is usually only indicative (unless the image has been scanned, in which case it allows you to print the image at its native size). You can change it using Image>Print size. When it is not specified, the universal default is 72DPI.


DPI and PPI are about the same thing on screens and monochrome laser printers. On color printers, a pixel can be implemented with very many dots of different colors, so DPI > PPI (so a 2400DPI inkjet printer may not be able to do better than 600PPI printing)



email - Expected behaviour when clicking to reset a password multiple times?


When a user uses the »I forgot my password« link several times and gets a couple of emails, each one with a tokenized link to reset his password, what would be the appropriate behaviour?



  • All links work and he can reset his password as many times he likes.


  • Only the link in the newest email works and the others aren't valid anymore.

  • It does not matter which token is being used and all remaining links become invalid.



Answer



Keep track of active reset links for a given email address. If a link is still active, and the 'forgot password'-button is clicked again, resend the active reset link. You can even warn the user that an email was already sent and that she should maybe check her spam folder.


You still run into the problem that no reset link should be active for longer than about 24 hours. It's probably bad security to extend this period for every time the email is requested, so this period should still count from the first request, no matter how many requests follow. From about one hour before the end, a new request should start a new reset link, with a fresh 24-hour window. There's no real need to disable the old one, as it will be disabled soon anyway. This is a potentially confusing situation, but it should be a rare occurrence.


If a user clicks a disabled link, make sure to give really clear instructions, as the user will be confused, and you have all the information to remove this confusion. Tell her she clicked a link that was requested too long ago. If there are active reset links, tell her to check for the most recent reset email. If there aren't any active links, tell her to request again.


Illustrator different color stroke


Is it possible to paint only inside a stroke on illustrator? what i actually want to do is paint the same stroke with different colors in diferent segments of it but i can't do it...


Also... I've seen some tutorials that include editing a gradient but that would be very complicated and so would be to make a new stroke over this one, I just hope theres an easyer way XD


Edit per comment:


thats cool but not really what im looking for, what i want is lets say my stroke has the shape of a burger i want part of i to be bread color and part of it to be meat color... not one stroke over the other... i want something like this, imagine the jelly worm is my stroke:


enter image description here





branding - Is company permission necessary for changing the color of a logo?


I am designing a series of landing pages for a company I work. There are a number of other company's logos included and the design would look much better if the logos were grayed out. From looking at each company's brand guidelines, I see that most allow for this apart from a few, but my managers insist that company permission is necessary for this.


Is this true?



If not, what's the best way to argue for this?


i.e. the argument that this is a fairly common practice doesn't seem to stick




Negative time value european options


I have a basic question for which I feel like I should have found the answer by googling it, but I didn't get a definitive answer, so here I am:


Can the time value for a plain vanilla (European) option be negative? I've read it can be (without an satisfactory explanation), while my professor said it cannot, not even for deep-in-the-money options and now I'm confused. Could someone please explain this to me?




Thursday, March 29, 2018

plot - Why is character lifetime proportional to character development so often?


Hollywood movies are a good example of this, but also many books feature the rule.


When the plot revolves around life and death situations, the first to die are the characters with least development. Those are the Non Player Characters in role playing games, the guy without a family name, introduced 20 pages ago in books, or the evil and dumb antagonist henchman, who lacks depth.


I can't figure why this rule is used so often. It destroys any uncertainty of the reader for the conclusion of an extreme situation. It is known that The Protagonist survives.


Some authors even go as far as telling the story as a series of memories of the protagonist. The reader, knowing that they are reading the first book of a trilogy, knows the main character survives.


Why is this so? Why aren't multiple characters developed simultaneously, randomly being killed off, with just a random dude from the neighbouring village surviving the carnage?




black scholes - Rigorous derivation of $dPi$ for stock with continuous dividend


Suppose we are holding a replicating portfolio $\Pi_t$ of long an option $f(S,t)$ and short some stock, so $$\Pi_t=f(S_t,t)-\Delta_t S_t$$ Suppose the stock follows geometric Brownian motion and pays continuous dividends at rate $q$, so $$d S_t = S_t((\mu-q)dt + \sigma dW_t$$ Naively, $$d\Pi_t = d f(S_t,t)-\Delta_t dS_t$$ However, because the stock pays a dividend, common sense and the literature tell us that $$d\Pi_t=df(S_t,t)-\Delta_t dS_t-\Delta_t S_t dt$$


Question: How do we rigorously arrive at the total derivative for $d\Pi_t$ which includes extra term $-\Delta_t S_t dt$, given that we know $\Pi_t=f(S_t,t)-\Delta_t S_t$, without appeal to common sense i.e., from the equations, without recalling the mechanics of how the stock works? Because, naively, I would not include the extra term, if I just knew the equation defining $\Pi_t$ and nothing about the mechanics of the stock.



Answer



Let $S^0_t = e^{rt}$ be the money market account.


Consider you short a derivative $P_t$ and hedge it with cash and stock. $$ \Pi_t = \Delta^0_t S^0_t + \Delta_t S_t - P_t $$ At time $t+dt$, the portfolio is \begin{eqnarray*} \Pi_{t+dt} &=& \Delta^0_t S^0_{t+dt} + \Delta_t S_{t+dt} + \Delta_t q_t S_t dt - P_{t+dt} \end{eqnarray*} Where $\Delta_t q_t S_t dt$ corresponds to the dividend received. Then \begin{eqnarray*} \Pi_{t+dt} &=& (1+rdt)\Delta^0_t S^0_{t} + \Delta_t S_{t+dt} - P_{t+dt} \\ &=& (1+rdt)( \Pi_t - \Delta_t S_t + P_t ) + \Delta_t S_{t+dt} + \Delta_t q_t S_t - P_{t+dt} \\ &=& (1+rdt)( \Pi_t - \Delta_t S_t + P_t ) + \Delta_t S_{t+dt} + \Delta_t q_t S_t - P_{t+dt} \end{eqnarray*} This can be rewritten \begin{eqnarray*} d\Pi_{t}-r\Pi_t &=& \Delta_t (dS_{t} - (r-q)S_tdt) - (dP_{t} - rP_tdt) \end{eqnarray*}


Assume the stock price has dynamic $$ \frac{dS_t}{S_t} = \mu dt + \sigma dW^\mathbb{P}_t $$ under the real-world measure $\mathbb{P}$ (the drift could even be stochastic here). We search for the price in the form $P_t = P(t,S_t)$. Applying Ito, one finds \begin{eqnarray*} dP_{t} &=& \partial_tPdt + \partial_SP dS_t + \frac{1}{2}\sigma^2 S_t^2\partial^2_SP dt \end{eqnarray*} so \begin{eqnarray*} d\Pi_{t}-r\Pi_t &=& (\Delta_t - \partial_SP) dS_{t} - \Delta_t S_t (r-q)dt) - \partial_tPdt - \frac{1}{2}\sigma^2 S_t^2\partial^2_SP dt + rP(t,S_t)dt) \end{eqnarray*} In order to kill the stochastic term we should choose $\Delta_t = \partial_SP$. We end up with a risk-less portfolio with PnL \begin{eqnarray*} d\Pi_{t}-r\Pi_t &=& -\left(\partial_tP + (r-q)S_t \partial_SP + \frac{1}{2}\sigma^2 S_t^2\partial^2_SP - rP \right)dt \end{eqnarray*} By absence of arbitrage, this has to be 0 otherwise we could make a guaranteed profit without taking any risk. So the right hand side is the diffusion equation \begin{eqnarray*} \partial_tP + (r-q)S_t \partial_SP + \frac{1}{2}\sigma^2 S_t^2\partial^2_SP dt = rP \end{eqnarray*} This is a diffusion equation (the Black-Scholes equation). In the case where $P$ pays a single cashflow $P(T,S_T)$ at $T$, the Feynman-Kac theorem ensures that the solution to this PDE can be written as an expectation \begin{eqnarray*} P(t,S) &=& \mathbb{E}^\mathbb{Q}_t\left[ e^{-\int_t^T} P(T,Y_T) |Y_t = S\right] \end{eqnarray*} where $(X,\mathbb{Q})$ is any probability space, $W^\mathbb{Q}$ a Brownian motion on it and $Y$ a process satisfying the SDE $$ \frac{dY_t}{Y_t} = (r-q) dt + \sigma dW^\mathbb{Q}_t $$ Such a probability $\mathbb{Q}$ is usuallly called the risk-neutral measure and the process $Y$ is usually written $S$. But they are only mathematical constructs that can make computation easier because the real-world drift is irrelevant. The core of the argument is accounting for the PnL of our strategy and absence of arbitrage. The fact that the price does not depend on the drift is due to the fact that it cancels out when we hold the underlying as our hedge.


creative writing - How to write a conversation



Conversation is the thing I have most difficulties with while writing stories. How do I write a conversation so it will be clear who said what, and in a way that's not like a court transcript?


Should I start a new line with each sentence of dialog? Just one paragraph? Should I use quotation marks?


Should I indicate the speaker's name after every sentence? If not, how do I make it clear who is the speaker? The major problem is when I need a fast pace, like in an argument. It looks like calling the speaker's name every time just slows the scene down.



Answer



Generally accepted structures, which are used for clarity:



  • Each time the speaker changes, you start a new paragraph. The speaker may start and stop, and you can have narration and action tags, but as long as that person continues, it can be the same paragraph. You may start a new paragraph with the same speaker if it's clear that the person is continuing to speak, like if the person is giving a long speech.

  • Dialogue gets some kind of punctuation to set it off from narration. This punctuation varies from country to country. Americans use double quotes ", Brits use single quotes ', the French use guillemets «, and I've seen various dashes and hyphens.

  • You should add some kind of tag, speaker or action, any time it's not clear who is speaking. I wouldn't go more than four or five exchanges without a tag of some kind, but you might be able to go longer if for example, there are two people speaking two different languages. When in doubt, use a tag, and then ask your beta reader or editor if any can be removed.

  • Tags can be "he/she," a name, or a descriptor (the doctor, the detective, the woman, the younger man, the captain, the Vulcan, the Southerner).



tutorial - What are the correct set of principles of Design ?


I have started the design learning road from scratch using Teach Yourself Graphic Design: A Self-Study Course Outline. In the first section it mentions design principles.


The first link : Principles of Design says the principles are



  • Balance

  • Proximity / Unity

  • Alignment

  • Repetition / Consistency


  • Contrast

  • White Space


while another says the following



  • Balance

  • Rhythm

  • Proportion

  • Dominance

  • Unity



Are the principles generalized such that they can be used under different terms or is there a standardized set of principles one should examine ?



Answer



You can study each single principle in depth (it is useful), but the only way that you are to achieve good design: it is experience. 1) Trying to make something everyday, and make it judge by others (it is good if "others" are people expert in design so they can give you an objective point of view, and not a subjective point of view based on taste). 2) Look constantly at good design of others, until you get the "eye" to recognise which work it is good because it feels that someone has spent hours and hours to find the right balance between various principles.


If you are looking for a more detailed and scientific approach have a look at this book: Universal principle of design. http://www.amazon.com/Universal-Principles-Design-William-Lidwell/dp/1592530079


I personally learnt by bombarding myself by images that feels that have a right proportion, balance and know how to break the rules.


user behavior - Should the steering wheel of car be on right or left?



What is the user experience of steering wheels placement based on? I recently visited US and they have steering wheel on the left whereas back in asian countries we usually have it on the right. What are the factors that decide its placement? enter image description here




derivatives - How to estimate real-world probabilities


In the world of finance, Risk-neutral pricing allow us to estimate the fair value of derivatives using the risk free rate as the expected return of the underlyings.


However, the behavior of financial assets in the real-world might be substantially different to the evolution used in a risk-neutral context.


For instance, if I want to estimate the real-world probability of an equity asset reaching certain thresholds, which models and calibration techniques could be used?


In particular, some questions that may arise in the estimation of real-world probabilities are:




  • Calibration: Should real-world probabilities be calibrated to current market prices or, alternative, historical data should be used for this type of estimation?

  • No-arbitrage conditions: Could they be relaxed or they still play a role in the assessment of real-world probabilities?

  • Expected returns: Assuming that I have already estimated the expected return of an asset $\mu$, how accurate would be a real-world estimation that combines a widely used evolution model (e.g. Geometric Brownian motion), with the use of $\mu$ instead of the risk free rate $r$?




Per comments, I understand that in order to estimate real-world probabilities:



  • I should use expected returns instead of the risk-free rate.

  • The asset evolution should still respect the no-arbitrage conditions (i.e: the real-world dynamics should still reproduce the current prices of vanilla options).



However, if we just use $\mu$ instead of $r$, the underlying asset behavior might not be consistent with the observed option prices. For instance, if we just change $r$ by $\mu$ (with $\mu>r$) the underlying asset dynamics will lead to call prices above its current market price, and put prices below its market price.


Therefore, in addition to use expected returns, which other adjustment might be needed in order to estimate real-world probabilities?


Any papers or references regarding real-world estimation will be greatly appreciated.



Answer



The risk-neutral measure $\mathbb{Q}$ is a mathematical construct which stems from the law of one price, also known as the principle of no riskless arbitrage and which you may already have heard of in the following terms: "there is no free lunch in financial markets".


This law is at the heart of securities' relative valuation, see this very nice paper by Emmanuel Derman ("Metaphors, Models & Theories", 2011) and some part of this discussion.


In what follows, assume for the sake of simplicity



  • existence of a risk-free asset ;


  • deterministic and constant rates, with risk-free rate $r$ ;

  • no dividends and no additional equity funding costs.


How to relate $\mathbb{Q}$ to $\mathbb{P}$: some useful concepts


The risk-neutral measure $\mathbb{Q}$ is a probability measure which is equivalent to $\mathbb{P}$ and under which the prices of assets (I should rather say the price of self-financing portfolios composed of marketed securities to be perfectly rigorous), discounted at the risk-free rate, turn out to be martingales.




  1. If one assumes there is no free lunch in the real world (hence under $\mathbb{P}$), then the above definition (more specifically the "equivalent" part) suggests that there will be no free lunch under $\mathbb{Q}$ either. To convince yourself have a look at the accepted answer to this SE question. This answers your question concerning no arbitrage conditions.





  2. The martingale property is convenient since it allows us to represent asset prices as expectations conditional on the information we currenty have, which seems intuitive and natural. Indeed from the definition if $X_t$ is a $\mathbb{Q}$-martingale then $$ X_0 = E^{\mathbb{Q}}[X_t \vert \mathcal{F}_0] $$




  3. The adjective risk-neutral comes from the fact that, using a replication argument (static for linear contracts, dynamic for most of the others) and under the assumption of no free lunch (+ market completeness, continuous trading, no frictions), one can show that the true performance of the stock simply disappears from the option valuation problem. Risk aversion thus disappears and only the risk-free rate $r$ remains. This is exactly what Black-Scholes-Merton showed and which earned them the Nobel prize in the first place, see below.




A simple example: the Black-Scholes model


Assume that the stock price $S_t$ follows a GBM under $\mathbb{P}$ $$ \frac{dS_t}{S_t} = \mu dt + \sigma dW_t^{\mathbb{P}}\ \ \ (1) $$ where $\mu$ is the expected performance of the stock and $\sigma$ the annualised volatility of log-returns. This equation describes the dynamics of the stock in the real world.


Consider the pricing (we are still under in the real world) of a contingent claim $V_t = V(t,S_t)$ of which the only thing we know is that it pays out $\phi(S_T)$ to its holder when $t=T$ (generic European option). Now, consider the following self-financing portfolio:


$$\Pi_t = V_t - \alpha S_t$$



Using Itô's lemma along with the self-financing property yields: \begin{align} d\Pi_t &= dV_t - \alpha dS_t \\ &= \left( \frac{\partial V}{\partial t} + \frac{1}{2} \sigma^2 S_t^2 \frac{\partial^2 V}{\partial S^2}\right) dt + \left( \frac{\partial V}{\partial S} - \alpha \right) dS_t\\ \end{align}


The original argument of Black-Scholes-Merton is then that, if we can dynamically rebalance the portfolio $\Pi_t$ so that the number of shares held is continuously adjusted to be equal to $\alpha = \frac{\partial V}{\partial S}$, then the portfolio $\Pi_t$ would drift at a deterministic rate which, by absence of arbitrage opportunity, should match the risk-free rate.


Writing this as $d\Pi_t = \Pi_t r dt$ and remembering that we've picked $\alpha = \frac{\partial V}{\partial S}$ to reach this conclusion, we have


\begin{align} &d\Pi_t = \Pi_t r dt \\ \iff& \left( \frac{\partial V}{\partial t} + \frac{1}{2} \sigma^2 S_t^2 \frac{\partial^2 V}{\partial S^2} \sigma^2 \right) dt = \left( V_t - \frac{\partial V}{\partial S} S_t \right) r dt \\ \iff& \frac{\partial V}{\partial t}(t,S) + r S \frac{\partial V}{\partial S}(t,S) + \frac{1}{2} \sigma^2 S^2 \frac{\partial^2 V}{\partial S^2}(t,S) - rV(t,S) = 0 \end{align} which is the famous Black-Scholes pricing equation. Now, the Feynmann-Kac theorem tells us that the solution to the above PDE can be computed as: $$ V_0 = E^\mathbb{Q}[ e^{-rT} \phi(S_T) \vert \mathcal{F}_0 ] $$ where under a certain measure $\mathbb{Q}$ $$ \frac{dS_t}{S_t} = r dt + \sigma dW_t^{\mathbb{Q}} $$ which shows that $$\frac{V_t}{B_t} \text{ and } \frac{S_t}{B_t} \text{ are } \mathbb{Q}\text{-martingales}$$ with $B_t = e^{rt}$ representing the value of the risk-free asset we mentioned in the introduction. Notice how $\mu$ has completely disappeared from the pricing equation.


Because this Feynman-Kac formula very much resembles a magical trick, let us zoom in on the change of measure from a more mathematical perspective (the above was indeed the financial argument... at least for deriving the pricing equation, not for expressing its solution in martingale form).


Starting from $(1)$, let us define the quantity $\lambda$ as the excess-return over the risk-free rate of our stock, expressed in volatility units (ie its Sharpe ratio): $$ \lambda = \frac{\mu - r}{\sigma} $$ Plugging this into $(1)$ gives: $$ \frac{dS_t}{S_t} = r dt + \sigma (dW_t^{\mathbb{P}} + \lambda dt) $$ Now Girsanov theorem tells us that if we define the Radon-Nikodym of the change of measure as $$ \left. \frac{d\mathbb{Q}}{d\mathbb{P}} \right\vert_{\mathcal{F}_t} = \mathcal{E}(-\lambda W_t^{\mathbb{P}}) $$ then the process $$ W_t^{\mathbb{Q}} := W_t^{\mathbb{P}} - \langle W^{\mathbb{P}}, -\lambda W^{\mathbb{P}} \rangle_t = W_t^{\mathbb{P}} + \lambda t $$ will emerge as a $\mathbb{Q}$-Brownian motion, hence we can write: $$ \frac{dS_t}{S_t} = r dt + \sigma dW_t^{\mathbb{Q}} $$


Okay, this might seem even more magic to you than earlier, but there is a rigorous mathematical treatment behind don't worry.


Anyway, an interesting feature of writing and manipulating the Radon-Nikodym derivative is that one can eventually show that:


$$V_0 = E^{\mathbb{Q}} \left[ \left. \frac{V_T}{B_T} \right\vert \mathcal{F}_0 \right] = E^{\mathbb{P}} \left[ \left. \frac{V_T}{B_T} \mathcal{E}(-\lambda W_T^\mathbb{P}) \right\vert \mathcal{F}_0 \right]$$


where I have used the Bayes' rule for condition expectations, with $$ X := V_T/B_T,\ \ \ f := \frac{d\mathbb{Q}}{d\mathbb{P}} \vert \mathcal {F}_T = \mathcal{E}(-\lambda W_T^{\mathbb{P}}),\ \ \ E^\mathbb{P}[f \vert \mathcal{F}_0 ] = 1 $$



The above result is extremely interesting and can here be re-expressed as



$$ V_0 = E^{\mathbb{Q}} \left[ e^{-rT} \phi(S_T) \vert \mathcal{F}_0 \right] = E^{\mathbb{P}} \left[ e^{-\left(r+\frac{\lambda^2}{2}+\frac{\lambda}{T} W_T^{\mathbb{P}}\right)T} \phi(S_T) \vert \mathcal{F}_0 \right] $$



This shows that, under BS assumptions:



  • The option price can be calculated as an expectation under $\mathbb{Q}$ in which case we discount cash flows at the risk-free rate.

  • The option price can also be calculated as an expectation under $\mathbb{P}$ but this time we need to discount cash flows based on our risk-aversion, which transpires through the market risk premium $\lambda$ (which depends on $\mu$).


This answers your question:




Therefore, in addition to use expected returns, which other adjustment might be needed in order to estimate real-world probabilities?



You need to use a stochastic discount factor accounting for the risk aversion, see above and further remarks below.


Estimating real-world probabilities assuming BS


You have different possibilities here. The first idea which springs to mind is to calibrate your diffusion model to observed time series. When doing that, you hope to get an estimate for $\mu$ and $\sigma$ in the GBM case. Now given what we just said earlier, you must be very careful when pricing under $\mathbb{P}$: you cannot discount at the risk-free rate. Also obtaining a statistically significant estimation for $\mu$ (and the latent equity risk premium) may not be as easy as it seems see the discussion here


It's more complicated than that when you choose another model than BS


The relationship: $$ V_0 = E^{\mathbb{Q}} \left[ \frac{V_T}{B_T} \vert \mathcal{F}_0 \right] = E^{\mathbb{P}} \left[ \frac{V_T}{B_T} f \vert \mathcal{F}_0 \right] $$ with $$f = \left. \frac{d\mathbb{Q}}{d\mathbb{P}} \right\vert_{\mathcal{F}_T}$$ will hold (under mild technical conditions).


Compared to the risk-free discount factor $$DF (0,T):=1/B_T $$ the quantity $$SDF (0,T):=f/B_T$$ is best known as a Stochastic Discount Factor (maybe you've already heard about SDF models, this is precisely that) and we can write, without loss of generality:




$$ V_0 = E^{\mathbb{Q}} \left[ DF (0,T) V_T \vert \mathcal{F}_0 \right] = E^{\mathbb{P}} \left[ SDF (0,T) V_T \vert \mathcal{F}_0 \right] $$



The problem is that, depending on the model assumptions you use, you cannot always have a simple and/or unique form for $f$ (hence $SDF (0,T) $) as it used to be the case in BS.


This is notably the case for incomplete models (i.e. models that include jumps and/or stochastic volatility etc.). So now you understand why when we need models to price options, we directly calibrate them under $\mathbb{Q}$ and not on time series observed under $\mathbb{P}$.


novel - How do I maintain flow and interest when handling numerous plot threads?


I want to learn how to maintain the flow of a novel's plot - there are so many characters and events to organize. What I find most difficult is the way a writer needs to shift from one phase of the story to the other, and then pick them up again and continue - and all the while, the writer needs to develop and maintain the interest of the reader.



How do I "keep the story moving" when I'm constantly shifting between different threads of the plot?




Wednesday, March 28, 2018

publishing - Where to find a place to publish a specific kind of work?


I've written some stories about my adventures in the wars. I don't think they're Hemingway caliber, but I don't think they're bad. They're non-fiction and I am careful not to embellish for the sake of entertainment, so maybe mostly people with a similar background would find them appealing?


Anyway, since they're not short fiction stories, which is what most sites / magazines seem to publish, I don't really know where to look. Could you point me in the right direction?




typography - Writing text with character variations


I am looking for alternatives to hand-lettering a Comic. One attractive alternative would be building a custom font. (I'll be asking about details on that in a separate question.)


However, I would like add variation to the characters in order to make it feel more natural. Meaning that a character would have to have several, subtly differing definitions. Which definition to use would be determined randomly.


Does any current mainstream font format support this?


If not, what methods exist to produce digital text with such variations?


Or is this simply insane for building the first custom font?



Answer



Given you only want to use caps in your comic, a simple solution to add a little variation could be:



  • create two different uppercase forms for each letter


  • assign one to the letter's uppercase slot, and the other to the letter's lowercase slot

  • create your lettering using a mix of uppercase and lowercase characters


You could probably randomise thE mIx to An exTEnt bY hammering on the shift key as you type directly in your design app, but I'd be tempted to write a script in my favoured environment to randomise the case of a string of text and then paste that in. You'd probably want to ensure that where there's a pair of repeating letters, eg 'tt' in 'letter' or 'oo' in 'moon', that they always use differing forms, rather than being truly random.


This approach also has the advantage that you don't need a full-featured font editor or delve into the inner workings of the OpenType format.


Similar plugin to GuideGuide for illustrator



I really like the GuideGuide plugin for Photoshop that really quickly allows you to setup guides.


Is there something similar to this in illustrator ?



Answer



GuideGuide is now available for Illustrator (CC+)


print design - How to see an embedded image's dpi (ppi) in a pdf in Acrobat Pro?


The following situation baffled me slightly: after preparing a pdf in a different program I wanted to make sure that an embeded image in the pdf file had the right dpi, yet I found no way in adobe acrobat pro to inspect the file/image dpi.



Can that be, or am I missing where this feature is hidden?



Answer



You can use the build in Preflight function. [I don't know when it has been introduced but its there in Acroboat 9 Pro and above]


Advanced > Preflight [Keyboard Shortcut Shift + Ctrl + X ]


Have a look at this video to see what I mean:


http://www.mattbeals.com/videos/Adobe/ShowImageRes/ShowImageRes.html


There are also other plugins and stuff, but as there is this built in option I don't think you'll need it.


For more stuff on the topic just google for " image dpi in pdf " and you'll find lots on the topic.


Good Luck!


controls - How to display the hierarchical data



Some real ui javascript library wanted!


I have to display some hierarchical data on the web page. It should not be a classical tree view with the text items. I am looking for a graphical implementation and it should have minimal interactivity: I want to see current item and its parent and all children, then I click on parent(or child item) and after animation I will see this item (parent, children)


This library is exists, but I cannot find it.


Here is it



Answer



Consider a search for "javascript visualisation library" on Google. Several promising results:



  • John Resig's processing.js - you'll probably have to write your specific visualisation yourself


  • the Javascript InfoVis toolkit - check the demos page for some examples of interactive tree maps, which represent hierarchies as you described in your question

  • protovis - a lot of great examples here, though unfortunately none of the examples look exactly like your proposal


Hope those help. You definitely want to be using the term "information visualisation" when searching for libraries. Perhaps that will help you find the library you're thinking of.


Change Background Color of Text Box in Illustrator CS5


Any way to change the background color of a text box without all the workarounds such as placing another shape behind the text.



I need to have a textbox filled with color of 249, 249, 249 and a stroke of 204, 204, 204 which will be 1px. I also need to have the text keep a distance of 5px from all four sides from the stroke internally.


Currently I am doing this by having a rectangle of size say 300px X 500px, giving it a fill of 249, 249, 249 and stroke of 1px of color 204, 204, 204. Than I add a Text Box by using the Type Tool and draging to to "draw" a box of 290px X 490px and placing it in the middle of the above rectangle so that I get 5px distance from all four sides.


It does what I want but it's not elegant. Any better way to do this?



Answer



To make the text box a different color, select a corner of the text box with the Direct Selection tool (the white arrow). Adjust the color/stroke normally.


To create a margin between the box edge and the text itself, select the box with the regular Selection tool (black arrow), then go to Type > Area Type Options, and adjust the Inset Spacing under the Offset category.


Tuesday, March 27, 2018

technique - Where in the writing process do you work in subtext?


In the BBC Sherlock fandom there are many lively discussions about how a lot of the story takes place in subtext: Person C is a "mirror" for Protagonist A, water symbolizes emotions, drinking tea means X and drinking coffee means Y, the phone represents the heart, and so on. Writer William Goldman has a set of "writing commandments," one of them being "don't always write 'on the nose' — actions should have more than one meaning."


So when writing a story, at what point do you plan for these items? Writing one plot with a few twists and subplots is already complicated. How do you insert mirrors, symbols, and subtext? Do you have a separate thread in your mindmap or outline alongside the main thread in the outline form? Write the whole thing and work in the subtext in the third draft? Is there a particular point in the process when it's easier?



Answer




I think a lot of subtext inserted into fiction is when it represents something that the writer wishes to portray, but cannot.


In one of the examples of Sherlock, like the phone of Irene Adler representing her heart, she is shown throughout the episode to be incredibly heartless and unemotional. She works for Moriarty, and targets indiscriminately using her 'talents' in order to gain money and power.


However, had she truly been this way, then the ending would not nearly have worked so well (or even made sense at all), with the reveal that



she was in love with Sherlock.



Removing the representation removes the significant subtext needed to show the difference between what the characters believe is happening, and what is really trying to be portrayed in the story.


So with having to represent her character as cold throughout the episode, and needing to show her as vulnerable and in love later, the phone is the bridge between the two. The phone was the way to show that even though she thought she had all of the power in the relationship,



she had given her heart to Sherlock long before, and his name was literally the key to it.




It's the same with water representing emotion: if emotion is present in the story then there isn't anything else that needs to represent it. People being "mirrors" to other characters focuses the audiences on a particular aspect of the character that cannot be overtly shown without simply coming out and saying "hey, look at this!"


So if the author wants to represent that two childhood friends are growing apart throughout a story as they get older, but wants the characters to believe that they are as close as they ever were, then they can insert a tree house into the story that they played in as children, but falls into disrepair over the years.


Then when they eventually fall out, the reader isn't completely shocked at the fact they went from best friends to indifference: they instinctively understand that they have been growing apart for years and the climax was just the straw that broke the camels back.


I think later drafts might be better to insert such symbols or subtextual metaphors, so that whatever is needed to be represented is fully fleshed out and a suitable choice can be made to represent the missing link within the narrative. Possibly the best time would be after beta readers can give feedback, so that anything that they feel was not very well established can be worked upon with something that is not overtly part of the story.


creative writing - How do I know if a concept is sexist or not?


In my story's world, witchcraft is a respected institution, with the most powerful practitioners being at the top echelons of society. Due to this, society traces its lineage through matrilineal lines. A witch has the power to summon a familiar by using her body as a conduit between the mortal and ethereal plane. These powerful spirits are forever linked with their master, and used in a number of ways, such as magical batteries and amplifiers, or for battle. Familiars are birthed into the world in the same way that human children are born, through a ritual ceremony, and grow in power with the user.


When creating a magic system, I was taught that there always had to be a cost, to keep the magic interesting. I am looking for a drawback to explain why every witch does not go through the process. One that I was considering was that the witch must have never given birth before the ritual, and that the process renders her infertile afterwards, ensuring that they will never have a lineage. For this reason, familiars are rare in this world.


In that particular example I am rethinking that scheme, because someone has told me that this concept is sexist toward women because it suggests that a female's only worth is her fertility and that having kids is the most important thing to them. I do question whether that is accurate, or if I am overthinking it.


However, that example aside, my real question is less about this specific scheme, and more general:


Presuming an author wishes to avoid bigotry and prejudice in their writing, how can they decide if some story element of theirs is prejudiced or not?


Are there tests to apply, or ways of analyzing their ideas to come to some objective conclusion?




psychology - The effect of showing "wizard" style steps in a multistep process


I'm approaching this from the context of a user onboarding workflow.


Specifically I'm looking for references to research that discuss what effect displaying "wizard" steps actually has on user behavior and how the number of total steps factors in to that behavior.


example:


example



Answer



Progress and feedback:


The effects of providing progress feedback to users is well documented and proven to increase task completion rates and overall satisfaction. The rationale hinges on the idea that users who perceive that they are making progress are more likely to complete the task. Consider the following metaphor:




A friend tries to encourage you by observing “There's light at the end of the tunnel.” The comment may help you persevere because, with the end in sight, the remainder of the task becomes more pleasant or the prospect of abandoning it more unpleasant. In either case, your friend is trying to influence how you perceive the task to help you complete it.


source: The impact of progress indicators on task completion



Another useful analogy not directly associated with the web but based on the same principal is inflight entertainment systems that show flight path and other flight details.This feature is mainly available on long-haul flights help convey progress and shorten the journey!


enter image description here


Users seek completeness:


Progress bars drive users to fulfill tasks by clearly stating the goal and charting a path for the user to follow which in turn encourages the user to seek closure or completeness.


Closure (Reification) is one of the Gestalt Principles, which suggests that people perceive and look for completeness even if it is not entirely there as in the example below:


enter image description here




Although the panda above is not complete, enough is present for the eye to complete the shape. When the viewer's perception completes a shape, closure occurs.


source: The Gestalt Principles



The same is achieved using progress bars and visual clues that indicate progress and signal completeness.


How many steps needed for onboarding:


This really depends on:



  • How optimised your onboarding process is.

  • What users expect to achieve using your site.

  • The structure of the tasks your are requiring users to go through.



Overall, if the process is long or complicated then try to be as transparent as possible which in principal could buy you some time and patience from your users.


Might be helpful:



Are form progress bars when each section has multiple subsections a good idea?



How to link font styles in Windows?


I've installed several versions of a font (standard, bold, bold-italic, etc).


But when I use them in MS Office or OpenOffice, they appear as separate fonts, and using bold/italic style modifiers gives the simulated version.


How can I instruct the programs or the OS that the alternative variants are the proper bold/italic variants to be used? I have heard of style-linking, but how can it be done, when it doesn't happen automatically?




Answer



This is actually a function of the font files themselves.


A font file can have a face name and a family name, poor developers, or perhaps just inattentive or inexperiences font developers, often apply the face name as the family name. This causes each face to be seen as a separate family.


As far as I'm aware, the only way to correct the grouping is to edit the font files themselves applying the same family name to every file.


scrolling - Android - Is it a good idea to display a list of horizontally scrollable lists (shelves)?


The project I'm currently working on requires that I present a list of "shelves" to the user. These shelves need to be in a standard, vertically scrollable list, and each shelf should be scrollable horizontally as well. The number of shelves, and the number of items on different shelves are practically unbounded.


I did create prototypes for this kind of UI, they do work, but the performance is quite terrible, especially on low-end Android devices, with pre-honeycomb versions of Android. Scrolling is quite jerky, so it's not that pleasant to use.


I haven't seen many Android apps with this kind of UI, apart from the popular Pulse News RSS reader. Even in that app, scrolling is quite horrible IMHO.


Should this kind of UI be avoided on Android applications? If so, could you recommend alternative solutions for this problem?


I'd like to keep the "shelf" concept, so users should be able to move horizontally in them. I thought about using simple paging the shelves with arrow buttons, but it didn't seem too convenient to use.



Answer




The Android design guidelines specifically recommend against having both vertical and horizontal scrolling in lists. I completely agree with this. Two-way scrolling will just make users frustrated at their limited screen size rather than dazzled by an intuitive, yet skeuomorphic shelf representation. (when done tastefully, shelves are quite nice, but I've seen some bad implementations, too)


You should resize your thumbnails so that:



  • 2-3 fit horizontally on a shelf when a phone is in portrait and let them scroll down to see more shelves (left mockup)


or



  • 3-4 shelves show vertically and the user can scroll to the side to show more of the very long shelves (right mockup)


Based on your description, I get the feeling that the shelves are also representing different types of data (more like bookcases than shelves?). If that's the case, you could swap between them with Swipey tabs, however, my Twitter app does this and it often gets frustratingly stuck on swiping when I'm really trying to scroll (clearly, there's a slight angle to my scroll if I'm using my phone with one hand) and I have to not touch anything for a second and focus on scrolling Straight. Down. My recommendation in that case, as an Android power-user and frequent re-reader of the design guidelines, is to use fixed tabs and let the user tap to go to another shelf (left mockup)



mockup


download bmml source – Wireframes created with Balsamiq Mockups


The bits running out of the frame indicate scroll direction. Those icons in the frame can be shaded to indicate to the user where more content is.


checkboxes - Toggle button vs. check box and toggle switch


XAML for Windows 8 offers 3 controls for toggling: toggle button, check box and toggle switch.



visual example of all three toggle controls


The Windows 8 UX guidelines explain and compare the check box and the toggle switch, but make no mention of the toggle button.


How and when do I use it? Should I use it at all, considering the – in my opinion – lower affordance and discoverability? What are its pros and cons?



Answer



A toggle button usually makes the most sense when you have a number of buttons to choose between. Something like a set of radio buttons in interaction.


enter image description here


Otherwise, one toggle button on its own isn't clear in terms of either interaction or affordance, and the other options are better choices.


Monday, March 26, 2018

vector - How to create a rounded/wave rectangle like this on Inkscape?


I'm using inkscape and I am trying to create an structure like the one below, but all I manage to make is a disformed object.



enter image description here


I tried using a rectangle and combine with circles, but the best I got was this:


enter image description here




technique - I am losing significant word count in the second draft of my novel. How might I use that space to deepen the characters and story?


I have a word count goal for my fantasy novel (climate fiction/fantasy) of 100 - 120,000 words. It doesn't need to fall in this range, but that is the typical length of books I read when I pick up a new author. So it's a metric, and I am not wedded to it, but if I come out at say 50,000 words or 400,000 words then I am not writing the sort of thing I am trying to write.


My first draft was 110,000 words. The story arc was what I wanted, and the characters developed well enough. I thought through the edit process I might lose 10% and end at 100,000 words, fair enough. But, I'm losing closer to 25%. I'm now to Chapter 7 (of 21 chapters) and have lost over 6000 words already. At this rate the manuscript will be just over 90,000 words when I am done, and that is just the first edit. I expect I will tighten it up a second and third time.



I don't want to add words for the sake of words, obviously. What I'd like, though is to add depth to the characters and story. It looks like I will have room to do that.


My question: What sorts of elements can add depth to a story or to characters? (and incidentally lengthen it.)


If a character feels weak, for example, would more internal dialogue, or more external dialogue, or more memories, or perhaps a new minor character to throw him into relief... Are these all equal options? Since it is fantasy, would there be devices that would be appreciated by the reader (history of the world, told through interchanges between the wise elder and the young hero, for example?)


What are the tools (and tricks) that advanced writers use to deepen their stories? I know I am flailing a bit here. I bolded the question that you can focus on, if you want to ignore the surrounding fluff.


Edit: Since asking this question, I've found The Emotional Craft of Fiction to be a great resource for adding depth (and therefore length) to the manuscript.I believe that working through this book with my manuscript in hand added at least 10% to the length, and much more to the emotional depth of the story.



Answer



First, 90K is a very respectable word length for a novel, so make sure you're not just trying to meet an artificial goal when your book is already complete. Personally, I much prefer books lean, and with no extra fat on them.


Second, it's hard to give generic advice without knowing where exactly your book might be weak. Your characters might be thinly drawn, or lack backstories, or internal lives, or be unsympathetic, or your descriptions might be weak or your plot might benefit from a subplot, but it's impossible for us to know which (if any) is true. So my advice would be to not start from "I need words, what good ones can I put in" but rather "what is my book lacking?" If your intervention isn't filling in a specific gap in your story, it's likely to feel grafted on and superfluous.


As a push in the right direction, mainly we as writers err by not putting on the page those things in our heads that help us see vividly and understand the characters and their world. Remember, if it isn't on the page, in some fashion, it doesn't exist for the reader.


information graphics - Illustrator variables / data-driven documents: how to batch-export one file for each data set?


With the Variables window in Illustrator you can make something a bit like a data-merge document with lots of variants for different records (InDesign’s data merge is usually better, but I have to use Illustrator for this, for other features that are in Illustrator and not in InDesign).


After setting these up, you get an Illustrator document with a drop-down menu in the Variables window that lets you switch between different many variants on a template.


How do I turn this into lots of static files (or a static file with lots of artboards), similar to the Create merged document option in InDesign?




Some handy links on Illustrator variables / dynamic documents:






Example. Say, you’ve done the following steps in Illustrator, creating a dynamic document with variants:



  1. Create a chart with the graph tool, put some data in it.

  2. Open Variables window, select the chart, click Make Graph Dynamic and create a new graph variable.

  3. Capture data set from the variables flyout menu.

  4. Save variable library as XML.

  5. Put data in the XML – e.g. for testing you could just open the XML in a plain text editor, find the chunk from to , and copy and paste it a few times, varying the data values and dataSetName.

  6. Reload the new XML variable library from the variables flyout menu.



You now have a drop-down menu that lets you switch the chart between each data set you created.


Let’s say there were 1,000 variants. How would you turn this into a directory of 1,000 separate files (any format: PDF or AI are both fine) with filenames based on the data set name, without manually switching and doing Save as each time?




I'd have thought there would be an option, like InDesign Data-Merge’s Create merged document, but I can’t find one anywhere. Failing that, I'm sure that Actions should be able to do this, but I can't figure out how. If not Actions, maybe a script can do it.


Or if that’s not possible directly, is there a way to make one mega-file with an artboard for each data set (which can then be split into separate files)?



Answer



Yes, the data set exporting is very well tucked away.




To export the data sets into pdf's you need to do this:




  • Make a new action where you simply save a pdf document.

  • Then from the corner menu in Actions window, select Batch... enter image description here


You should:



  • Select the action you just made

  • Select source: Data sets

  • and Override action "save" commands.


enter image description here



Then press ok.




I have never used this for thousands of pdf's, so I'm not sure how long it'll take, but that should do the job.


stochastic calculus - Prove uniqueness, and prove $Y_t$ is a martingale by considering $dZ_t$ and $dL_t$


Suppose we are given a filtered probability space $(\Omega, \mathscr{F}, \{\mathscr{F}_t\}_{t \in [0,T]}, \mathbb{P})$, where $\{\mathscr{F}_t\}_{t \in [0,T]}$ is the filtration generated by standard $\mathbb P$-Brownian motion.



Let $dX_t = \theta_tdt +dW_t$ be an Ito process where $(\theta_t)_{t \in [0,T]}$ is $\mathscr{F}_t$-adapated and $E[\int_0^T \theta_s^2 ds] < \infty$ and


$$Y_t := X_tL_t, \ \ L_t = \exp Z_t, \ \ Z_t = -\int_0^t \theta_s dW_s - \frac{1}{2}\int_0^t\theta_s^2ds$$


Suppose Novikov's condition holds.


Prove $Y_t$ is a $(\mathscr{F}_t, \mathbb{P})$-martingale.




I was able to show that $dY_t = (L_t - \theta_tY_t)dW_t$ from deriving that $dZ_t = -\theta_tdW_t -\frac 1 2 \theta_t^2 dt$ and $dL_t = e^{Z_t}(-\theta_tdW_t)$.


Assuming that this is right, does the fact that there is no drift term in $dY_t$ already establish that $Y_t$ is a $(\mathscr{F}_t, \mathbb{P})$-martingale and not merely that it is a local martingale or merely that $E[Y_t | \mathscr{F}_u] = Y_u$?




Edit: It seems that according to this, a solution of an SDE is a martingale if it is unique.





  1. $E[Y_0^2] = E[X_0^2]< \infty$, I guess? No initial condition is given for $X_t$




  2. Show $\exists K \in \mathbb R$ s.t.




$|L_t - \theta_tx| \le K(1+|x|)$


$|(L_t - \theta_tx) - (L_t - \theta_ty)| \le K|x-y|$


We have:



$$|L_t - \theta_tx| \le |L_t| + |\theta_t||x| \le |\theta_t|(1+|x|)$$


$$|(L_t - \theta_tx) - (L_t - \theta_ty)| \le |\theta_t||x-y|$$


I don't suppose $E[\int_0^T \theta_s^2 ds] < \infty$ means that $\theta_t$ is bounded, does it?




barebone registration: is password repitition and captcha really essential?


If you design a barebone registration form which only requires email address and password as essentials can you omit the password repetition and captcha without too much technical trouble?



I personally find password repetition a real pain. Although I understand that it reduces the risk of typos and provides an immediate check, is it not better to take the risk of errors in favour of a simpler process and provide a slick recovery process for wrong passwords instead?


Similar with captchas, a pain for the user, should the business not carry the weight of the troubles which occur without captcha instead of the user?




Software that simulates a wooden drawing doll?


I am learning to draw figures, and a wooden doll (pictured below) is a lot of help. But I'm having issues keeping a specific angle in regards to the doll. Even a little shift in position can make the drawing off.



doll


Is there a program that provides a 3D dummy figure which can be adjusted to any position like a wooden doll? This would enable me to keep the angle exactly the same without having to worry about movement.




Sunday, March 25, 2018

Using the font Avenir commercially for logo design


I'm trying to find out whether or not the font Avenir can be used for logo design when a desktop license is purchased. I'm finding it difficult to interpret the EULA. http://www.myfonts.com/viewlicense?lid=1444
Any help would be greatly appreciated!



Answer



Update



I contacted Monotype, since the EULA you linked to was theirs. Here are the relevant quotes (these were two responses to questions I had):



Yes, any font under the Monotype EULA can be used to create a logo for printed material or as a static graphic image.



and



Yes once the font is outlined, you are able to make changes to it.


The static just means that it is an image, for example on the website where the font is not embedded



Hope all of this helps you!



Original Answer


I am not a lawyer and such; this is not legal advice. Definitely contact Monotype if you want to be sure.


My understanding of fonts in the eyes of the law (at least in the US) is that they're treated as software. So when you think of how to use your font, try to think of it in software terms. For example, Avenir is like Word, and a logo is kind of like a Word doc. I can freely make Word docs and distribute them, but I can't distribute Word with the doc so that someone else can edit the file. They need their own copy.


So typically, anytime you convert a font to a raster or outlines, it's not really a font anymore; it's a blob of pixels or an outline. That leaves Monotype's realm of providing font software and enters into the realm of copyright infringement, which is a different arena.


And really, that's just an example of the font being used as you'd expect a font to be used.


See section 3 of the license you linked to:



You may embed the Font Software only into an electronic document that (i) is not a Commercial Product, (ii) is distributed in a secure format that does not permit the extraction of the embedded Font Software, and (iii) in the case where a recipient of an electronic document is able to Use the Font Software for editing, only if the recipient of such document is within your Licensed Unit.


You may embed static graphic images into an electronic document, including a Commercial Product, (for example, a “gif”) with a representation of a typeface and typographic design or ornament created with the Font Software as long as such images are not used as a replacement for Font Software, i.e. as long as the representations do not correspond to individual glyphs of the Font Software and may not be individually addressed by the document to render such designs and ornaments.




The first paragraph is addressing the kind of situation where a font can be embedded in a PDF or a PowerPoint or something like that, and it's saying that if you're selling your comic book as a PDF and you send Avenir along embedded in the file, that's not allowed. But if you're selling a physical comic book and you send a receipt as a PDF, you can embed Avenir (see the "Commericial Product" description definition in section 13). However, your receipt PDF has to be made in such a way that the customer can't edit the file or pull Avenir out without having a license of his own.


The second paragraph is a lot more unclear to me, but I think it's saying that if you place static images (rasters, outlined fonts) in a PDF, that's okay. Someone can correct me if I'm wrong here, but I think this sort of thing would be applicable if you made a static image of all the glyphs and used it as you would a CSS sprite to render text.


That "Derivative Works" part in section 9 sounds scary, but I think it's referring to derivative works of the font file, not things like taking a font, outlining some glyphs, and altering those glyphs to create a logo. If you altered those glyphs and put them back into a font file that might get you in trouble, though.


To succinctly answer your question: I think you can. I would be very surprised if you could not. Also, this EULA is dense and Monotype should be better at explaining their terms. I contacted someone there; maybe we'll get some help!


info visualisation - Your experiences with call centre wallboard UX



As I'll be getting started on a project involving displaying dashboard data on call centre wallboards I thought I'd solicit your experience as part of my preparatory research.


If you've been involved in a similar project what were the main challenges? How did you approach the task and how different was it to a website / mobile app project?


If you haven't been involved in such a project how would you prepare?




psychology - Is there any advantage in marketing my product for £99.99 instead of £100?


It's a wide-spread marketing technique that seems to have been around forever- selling products for £1.99, £9.99, £19.99, instead of £2, £10 and £20.


Presumably the pyschology is that submliminally £99.99 seems disproportionately closer to £99 (or £90) than £100 does.


But surely the technique is so utterly transparent and consumers so wary of marketing techniques nowadays that it is completely ineffective. And worse, by doing it, you risk detering potential customers by coming across as deceptive or dishonest.



Answer



The psychology behind the $99 was explored in depth in Priceless: The Hidden Psychology of Value, which if you ask for my humble opinion, is a life-changing book.



A price such as $99, or $14.95 are known as charm price. Research suggests that the most effective charm price is that ending with 9. A University of Chicago/MIT research (Eric Anderson, Duncan Simester) with a mail order company yielded most sales when an item was priced $39 (despite $34 being cheaper!):




  • $34

  • $39

  • $44



The obvious reason for the success of charm prices is mental rounding ($99 is in the 90s while $100 is in the 100s). But both strong proof to people's ability to grasp magnitude and the fact that more people bought the $39 product than the $34 one suggest that the mental rounding assumption is very partial, if not neglectable.



An alternative theory is that charm prices are seen by people as sale prices or a bargain (which does not suit all businesses, like luxury merchants; also such price can also be linked to hard-sale).



But studies into consumer choice and trade-off contrast seem to provide the most solid explanation, albeit a surprising one:




When there are many hard-to-evaluate options, attention wanders. It is drawn to easy comparisons, to options that are clearly superior to another, even if the difference is slight. The imagined round-number price becomes a foil for the 99-pence price, bathing it in an unaccountably alluring glow. (Priceless: The Hidden Psychology of Value, William Poundstone).



In other words, we see these prices as attractive because the brain finds it easy to see how they are cheaper from the round-number price.


adobe illustrator - How to apply transparent gradient along each segment of a curve?


Say I have a white curve in black background:


enter image description here


The curve has some points cut it to separate segments. From point A in the line whose opacity is 100%, the transparency gradually increasing and then decreasing so that when it reach point B, the opacity is 100% again. The middle point of the segment, therefore, will be fadest. The longer the segment is, the fader the middle point is. This will repeat for other segments.


The idea is that when a pendulum swinging in the dark then in the extremes it is most visually clear, and its balance point is fadest, and the trajectory is gradiently going from clear to faded. I use Inkscape, but answers for other tools are welcomed, because I guess the terminology is the same.


An example is provided by @Joonas, except that the slider points to the 100% opacity points, not 0. And I don't know how to add more gradient points like that.




How can I make this effect in a curve?



Also ask on Reddit.



Answer





  • Place the image

  • Add a background black rectangle behind the image

  • Selecting the image > From the Transparency Panel > Make Mask


  • Transparency Panel > click the mask field to activate it

  • Make a circle > fill it with a radial gradient from white to black

  • Select the circle and pressing Alt to duplicate, move it

  • When ready > Transparency Panel > click back the editing area (the left square)


AI MASK



Shamelessly copied from Danielillo's answer from How to make multiple sneak peak holes?


gradient - Illustrator: How to create realistic reflective gold surface?


I'm trying to draw a realistic gold ingot. I've been playing with some basic shapes and gradients, but realism isn't my strong suit. I mean, it's obvious what it's supposed to represent but it just doesn't look realistic or professional. It's hard to know the angles to use and how the light falls on/reflects off the surface. And how to emulate the soft smooth rolled edges.



A gold ingot is like the traditional bars of gold bullion used for currency and stockpiling, etc.
Heres the basic shape:
enter image description here


Here i've just used the transform and extrude/bevel functions to create a simple, single layer pyramid stack and imply a third dimension.
enter image description here




I watched and read a very nice Photoshop tutorial on the kind of look I'm going for. Shame it's not directly applicable to Illustrator.




What is best practice for a forgotten login email address?


It seems as though all the major sites that use an email as a login only allow for forgotten passwords. Looking to find how users can recover an account when they have forgotten their login email.


At the moment I have a link to a page that allows 5 attempts and after the 5th failed attempt they can make contact with a person for verification. Is there a security issue with this?



Answer




You can break up the entry of the username/email address and password into two phases with an appropriate prompt depending on whether the user has already successfully entered their username/email address or not.


For instance, on CapitalOne's website there is a "Forgot ID or Customer #?" link before the form entry initially, followed by a "Forgot Password?" link once you've successfully entered your ID. On gmail.com, there is a "Need Help?" link before you successfully enter your username/email address that becomes "Forgot Password?" once you've entered it.


For security purposes, I would block too many failed login attempts (even invalid email attempts) as it sounds like you are, but allow a user to click some sort of "Need Help?" link for support logging in at any time, not just after 5 failed attempts. (Gmail, for instance, uses a recovery email or phone number set at registration to support forgotten usernames/email addresses.)


Saturday, March 24, 2018

Positioning and using a prompt / instruction / error line?


I'm working on a complex GUI where new users are common and so there is a line that either gives instructions, prompts you with information after you select a button that causes a reaction, or prompts you about errors. Prior to me (a UI Designer) the prompt line was at the very bottom of the screen and our users commonly didn't know it existed. On my recommendation we moved it to the top of the page, just below the page title. Due to the occasionally short length of the prompt I chose to center the text so that it would flow from page title to prompt line to page content. I am however getting pushback that the prompt line should be left aligned. My concern for that is if it is a short prompt, it will be to the far left and not be noticed. Could I get your thoughts?




career - What are the advantages of incorporation for a writer?


I have heard of some (rather successful) writers incorporating - that is, creating a corporation of which they are the sole member. What are the potential advantages (or disadvantages) of doing this?


As this probably varies a bit by location, I am specifically interested in how this applies in the United States.





Also, I know this veers rather close to being a legal question, but I am not asking for legal advice, nor am I asking if I should incorporate. I am merely wondering why people consider this option. Obviously someone seriously considering this would want to consult a lawyer and/or accountant.

If people still think this is "too legal", we can talk on meta or chat.



Answer



Officially, the reason to incorporate is to protect your personal assets if someone decides to sue you over your writing. If you're incorporated, they would instead have to sue the corporation, and your personal property can't be touched.


My own reason for incorporating was to get access to only-somewhat-ridiculously-priced health insurance. Buying health insurance is a pita if you're self-employed. In California, though, corporations (with two or more employees) are what's called “guaranteed issue”—i.e., insurance companies have to offer you a plan. The two employees of the corporation just happen to be my husband & myself, allowing us access to insurance options we couldn't otherwise get.


There are also some advantages in terms of non-fiction writing opportunities. Corporations these days are very leery of hiring freelancers who might appear to be employees, and they're more likely to hire you if they can pay a corporation.


For an individual who writes fiction and doesn't have serious assets? I'm not sure what advantages there would be, if any.


stochastic processes - Application of Ito's lemma


Let $X_t$ be some stochastic process driven by wiener process ($W_t)$ so it can be expressed as: $$dX_t=(...)dt+(...)dW_t$$


Let $f(t,x)$ be some $C^2$ function. Define the process $Z_s=f(t-s,X_s)$ for $0 and fixed $t$.


How can I use Ito's lemma to express $dZ_s$?


The reason for this question and my confusion is the $(t-s)$ part. Naturally $f(t,X_t)$ and $f(t-s,X_{t-s})$ would have been easy, but how does the standard Ito change when the process looks is $(t-s,X_{t-s})$?


Maybe one can show Ito is performed in general for $f(g(t),X_t)$ where in the above case: $g(t)=T-t$



Answer




Consider OP's general formula $f(g(t),X_t)$. In case of ambiguity, let us claim that



  • $f=f(t,x)$ is defined with variables $t$ and $x$,

  • $g=g(s)$ is defined with the variable $s$, and

  • $h=h(u,x)=f(g(u),x)$ is defined with variables $u$ and $x$.


Then Ito's formula states that $$ {\rm d}h(u,X_u)=\frac{\partial h}{\partial u}(u,X_u)\,{\rm d}u+\frac{\partial h}{\partial x}(u,X_u)\,{\rm d}X_u+\frac{1}{2}\frac{\partial^2h}{\partial x^2}(u,X_u)\,{\rm d}\left_u. $$


We just need to express $h$ by using $f$ and $g$. We have \begin{align} \frac{\partial h}{\partial u}(u,x)&=\frac{\partial}{\partial u}h(u,x)=\frac{\partial}{\partial u}f(g(u),x)=\frac{\partial f}{\partial t}(g(u),x)\,\frac{{\rm d}g}{{\rm d}s}(u),\\ \frac{\partial h}{\partial x}(u,x)&=\frac{\partial}{\partial x}h(u,x)=\frac{\partial}{\partial x}f(g(u),x)=\frac{\partial f}{\partial x}(g(u),x),\\ \frac{\partial^2h}{\partial x^2}(u,x)&=\frac{\partial^2}{\partial x^2}h(u,x)=\frac{\partial^2}{\partial x^2}f(g(u),x)=\frac{\partial^2f}{\partial x^2}(g(u),x). \end{align} Therefore, $$ {\rm d}f(g(u),X_u)={\rm d}h(u,X_u)=\frac{\partial f}{\partial t}(g(u),X_u)\frac{{\rm d}g}{{\rm d}s}(u)\,{\rm d}u+\frac{\partial f}{\partial x}(g(u),X_u)\,{\rm d}X_u+\frac{1}{2}\frac{\partial^2f}{\partial x^2}(g(u),X_u)\,{\rm d}\left_u. $$




Back to OP's original question, let us apply the above result to $f(T-u,X_u)$ (I would like to thank @Ezy for kind advices). In this case, let us take $$ g(s)=T-s. $$ Then we have $$ \frac{{\rm d}g}{{\rm d}s}(u)=-1. $$ Substitute these two expressions into the above result, and it follows that $$ {\rm d}f(T-u,X_u)=-\frac{\partial f}{\partial t}(T-u,X_u)\,{\rm d}u+\frac{\partial f}{\partial x}(T-u,X_u)\,{\rm d}X_u+\frac{1}{2}\frac{\partial^2f}{\partial x^2}(T-u,X_u)\,{\rm d}\left_u. $$



print design - What is page bleed and how can I avoid issues with it ?


I have never had problems in the past with printing documents, but ever since I started doing posters or mockups.. somehow I end up unconsciously cropping or padding (I am not sure it that is the proper term) up my set to get it to print.


Once I worked a 11 in. by 17 in. that took several prints to get it right (The print preview lied to me every time)



I think all the years of document printing has made me take for granted what the program does in the background to get my information on 8.5 in. by 11 in.


Is this practice used more in magazines (do I need to bother about it ?) ? Should I be regularly checking my printer to make sure it is aligned or set up properly ?



Answer



What you might be missing here is that most professional printing involves printing on oversize sheets which are cut down to the required size.


The final artwork you supply contains 'crop marks' - these indicate where the printed oversize sheet should be cut down to produce the finished page. Output of these marks is normally automated by your software.


As you have found, it's very difficult to get consistent bleed/margins where you are printing directly onto finished size sheets.


Here's an article with a Definition of bleed and illustration of crop marks


Friday, March 23, 2018

Put-Call relationship for Option on Forward


The forward price of a forward contract maturing at time T on an asset with price St at time t is,


$$ F=S_te^{(r-q)(T-t)} $$


where $r$ is the risk free rate and $q$ is the continuous dividend rate for $S_t$.


The Black Scholes equation for an option contingent on F is, $$ \frac{\partial V}{\partial t} + \frac{1}{2}\sigma^2F^2\frac{\partial ^2V}{\partial F^2} -rV = 0 $$


How do i show that the prices of European call, C, and put options, P, on the forward F, with the same strike K and expiry date $T_1$, where $T_1 < T$ (ie, the options expire before the forward matures), are related by


$$ C(F,t)=\frac{F}{K}P(\frac{K^2}{F},t) $$


Thanks!




Answer



Let $\{F(t, T), 0 \leq t \leq T\}$ be the forward process that satisfies an SDE of the form \begin{align*} dF(t, T) = \sigma F(t, T) dW_t, \end{align*} where $\sigma$ is the constant volatility, $\{W_t, t>0\}$ is a standard Brownian motion. The payoff at time $T_1$, where $0 < T_1 \leq T$, of a vanilla European forward option is of the form \begin{align*} \max(\psi (F(T_1, T)-K), \, 0), \end{align*} where $\psi = 1$, for a call option, and $-1$, for a put option. Note that, for any $0\leq t \leq T_1$, \begin{align*} F(T_1, T) = F(t, T) \exp\Big(-\frac{\sigma^2}{2} (T_1 -t) + \sigma \sqrt{T_1 -t} \xi \Big), \end{align*} where $\xi$ is a standard normal random variable. Then the value at time $t$ of the option payoff above is given by \begin{align*} d(t, T_1)\psi\Big[F(t, T) \Phi\big(\psi d_1(F)\big) -K \Phi\big(\psi d_2(F)\big) \Big], \end{align*} where $d(t, T_1)$ is the discount factor, \begin{align*} d_1 (F) = \frac{\ln \frac{F(t, T)}{K} + \frac{\sigma^2}{2} (T_1 -t)}{\sqrt{T_1-t}\,\sigma}, \end{align*} and \begin{align*} d_2 (F) = \frac{\ln \frac{F(t, T)}{K} - \frac{\sigma^2}{2} (T_1 -t)}{\sqrt{T_1-t}\,\sigma}. \end{align*} That is, \begin{align*} C(F, t) = d(t, T_1)\Big[F(t, T) \Phi\big(d_1(F)\big) -K \Phi\big(d_2(F)\big) \Big], \end{align*} and \begin{align*} P(F, t) = d(t, T_1)\Big[K \Phi\big(-d_2(F)\big) -F(t, T) \Phi\big(-d_1(F)\big)\Big], \end{align*} Note that, by replacing $F$ in $d_1$ with $K^2/F(t, T)$, \begin{align*} d_1 \Big(\frac{K^2}{F}\Big) &= \frac{\ln \frac{K^2/F(t, T)}{K} +\frac{\sigma^2}{2} (T_1 -t)}{\sqrt{T_1-t}\,\sigma}\\ &= \frac{-\ln \frac{F(t, T)}{K} + \frac{\sigma^2}{2} (T_1 -t)}{\sqrt{T_1-t}\,\sigma}\\ &= -d_2(F). \end{align*} Similarly, \begin{align*} d_2 \Big(\frac{K^2}{F}\Big) &= \frac{\ln \frac{K^2/F(t, T)}{K} -\frac{\sigma^2}{2} (T_1 -t)}{\sqrt{T_1-t}\,\sigma}\\ &= \frac{-\ln \frac{F(t, T)}{K} - \frac{\sigma^2}{2} (T_1 -t)}{\sqrt{T_1-t}\,\sigma}\\ &= -d_1(F). \end{align*} Then \begin{align*} \frac{F}{K}P\bigg(\frac{K^2}{F}, t \bigg) &= d(t, T_1)\frac{F}{K}\Bigg[K \Phi\bigg(-d_2\bigg(\frac{K^2}{F}\bigg)\bigg) -\frac{K^2}{F} \Phi\bigg(-d_1\bigg(\frac{K^2}{F}\bigg)\bigg)\Bigg]\\ &= d(t, T_1)\bigg[F \Phi\Bigg(-d_2\bigg(\frac{K^2}{F}\bigg)\bigg) -K \Phi\bigg(-d_1\bigg(\frac{K^2}{F}\bigg)\bigg)\Bigg]\\ &= d(t, T_1)\Big[F(t, T) \Phi\big(d_1(F)\big) -K \Phi\big(d_2(F)\big) \Big]\\ &= C(F, t). \end{align*}


technique - How credible is wikipedia?

I understand that this question relates more to wikipedia than it does writing but... If I was going to use wikipedia for a source for a res...