Outline Announcements –HW II due Friday –HW III option Interpolation Colormaps.

Slides:



Advertisements
Similar presentations
Lecture 3 HSPM J716. Efficiency in an estimator Efficiency = low bias and low variance Unbiased with high variance – not very useful Biased with low variance.
Advertisements

Chapter 15 Above: GPS time series from southern California after removing several curve fits to the data.
Chapter 11 Above: Principal contraction rates calculated from GPS velocities. Visualized using MATLAB.
Interpolation, color, & light. Outline Announcements –HW II--due today, 5PM –HW III on the web later today HW I: Issues Structured vs. Unstructured Meshes.
CITS2401 Computer Analysis & Visualisation
EARS1160 – Numerical Methods notes by G. Houseman
ES 240: Scientific and Engineering Computation. InterpolationPolynomial  Definition –a function f(x) that can be written as a finite series of power functions.
Spatial Interpolation
Analysis of different gridding methods using “Surfer7”
Spatial Interpolation
Role and Place of Statistical Data Analysis and very simple applications Simplified diagram of scientific research When you know the system: Estimation.
Lecture 9 Interpolation and Splines. Lingo Interpolation – filling in gaps in data Find a function f(x) that 1) goes through all your data points 2) does.
Statistics and Simple Plots. Outline Announcements: –Homework II: due Wed. by 5, by Cookie Challenge Statistics Simple plots Tutorial 4.
Role and Place of Statistical Data Analysis and very simple applications Simplified diagram of a scientific research When you know the system: Estimation.
Lecture 07: Terrain Analysis Geography 128 Analytical and Computer Cartography Spring 2007 Department of Geography University of California, Santa Barbara.
Applications in GIS (Kriging Interpolation)
Image Morphing, Thin-Plate Spline Model CSE399b, Spring 07 Computer Vision
Slope and Aspect Calculated from a grid of elevations (a digital elevation model) Slope and aspect are calculated at each point in the grid, by comparing.
 1999 BG Mobasseri1 8/29/2015 MATLAB GRAPHICS - PART II ADVANCED PLOTTING June 4, ‘99.
1 Computer Graphics Week13 –Shading Models. Shading Models Flat Shading Model: In this technique, each surface is assumed to have one normal vector (usually.
Intro. To GIS Lecture 9 Terrain Analysis April 24 th, 2013.
Recap Summary of Chapter 6 Interpolation Linear Interpolation.
1 Lesson 8: Basic Monte Carlo integration We begin the 2 nd phase of our course: Study of general mathematics of MC We begin the 2 nd phase of our course:
Explorations in Geostatistical Simulation Deven Barnett Spring 2010.
Geog. 579: GIS and Spatial Analysis - Lecture 21 Overheads 1 Point Estimation: 3. Methods: 3.6 Ordinary Kriging Topics: Lecture 23: Spatial Interpolation.
Curve Fitting and Regression EEE 244. Descriptive Statistics in MATLAB MATLAB has several built-in commands to compute and display descriptive statistics.
Polynomial Interpolation You will frequently have occasions to estimate intermediate values between precise data points. The function you use to interpolate.
Geographic Information Science
Introduction to MATLAB 7 Engineering 161 Engineering Practices II Joe Mixsell Spring 2010.
Geo479/579: Geostatistics Ch16. Modeling the Sample Variogram.
Spatial Statistics in Ecology: Continuous Data Lecture Three.
The Semivariogram in Remote Sensing: An Introduction P. J. Curran, Remote Sensing of Environment 24: (1988). Presented by Dahl Winters Geog 577,
Computational Methods of Scientific Programming Lecturers Thomas A Herring, Room A, Chris Hill, Room ,
Advanced Computer Graphics Advanced Shaders CO2409 Computer Graphics Week 16.
Spatial Interpolation III
Statistics and Simple Plots. Outline Announcements: –Homework II: due Today. by 5, by Statistics Simple plots.
Spatial Interpolation Chapter 13. Introduction Land surface in Chapter 13 Land surface in Chapter 13 Also a non-existing surface, but visualized as a.
Spatial Analysis & Geostatistics Methods of Interpolation Linear interpolation using an equation to compute z at any point on a triangle.
2D Routines in 3D. Outline Announcements –HW II--due Friday. 5PM HW1 & Cookie Grids & Meshes Representing f(x,y) Lines & Surfaces in 3D Survey.
CS 325 Introduction to Computer Graphics 03 / 29 / 2010 Instructor: Michael Eckmann.
Numerical Analysis 3D Plots. A numerical method is a technique for computing a numerical approximation of the solution to a mathematical problem.
Recap Plots with More than one Line Plots of Complex Arrays Line, Color and Mark Style Axis Scaling and Annotating Plots Subplots Polar Plots Logarithmic.
Volumetric Visualization. Outline Announcements –PS III due today –contest entries by tomorrow –PS IV online today--GUI vs. VV –Demos on Friday What is.
Lecture 6: Point Interpolation
Recap Cubic Spline Interpolation Multidimensional Interpolation Curve Fitting Linear Regression Polynomial Regression The Polyval Function The Interactive.
Lecture 21 MA471 Fall 03. Recall Jacobi Smoothing We recall that the relaxed Jacobi scheme: Smooths out the highest frequency modes fastest.
Shape from Shading Course web page: vision.cis.udel.edu/cv February 26, 2003  Lecture 6.
Mohiuddin Ahmad SUNG-BONG JANG Interpolation II (8.4 SPLINE INTERPOLATION) (8.5 MATLAB’s INTERPOLATION Functions)
Interactive Graphics Lecture 10: Slide 1 Interactive Computer Graphics Lecture 10 Introduction to Surface Construction.
Recap Functions with No input OR No output Determining The Number of Input and Output Arguments Local Variables Global Variables Creating ToolBox of Functions.
Section 1.6 Fitting Linear Functions to Data. Consider the set of points {(3,1), (4,3), (6,6), (8,12)} Plot these points on a graph –This is called a.
Handle Graphics and 1D Primitives Some Handel graphics.
Introduction to Engineering Calculations Chapter 2.
Outline Announcements: –HW I key online this afternoon –HW II due Friday –Sign up to discuss projects Debugging Testging for correctness.
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Part 4 Chapter 17 and 18 Interpolation.
R. Kass/W03 P416 Lecture 5 l Suppose we are trying to measure the true value of some quantity (x T ). u We make repeated measurements of this quantity.
David Luebke3/16/2016 CS 551 / 645: Introductory Computer Graphics David Luebke
EEE 242 Computer Tools for Electrical Engineering
Advanced Plotting Techniques Chapter 11 Above: Principal contraction rates calculated from GPS velocities. Visualized using MATLAB.
Reading and Writing Image Files
2D Routines in 3D.
Chapter 14 Shading Models.
Computer Vision Lecture 4: Color
Inference for Geostatistical Data: Kriging for Spatial Interpolation
Statistical Methods For Engineers
Lecture 20: Spatial Interpolation III
Interpolation & Contour Maps
Spatial interpolation
Computer Graphics Material Colours and Lighting
Geostatistical Simulations – Preparing for Worst-Case Scenarios
Presentation transcript:

Outline Announcements –HW II due Friday –HW III option Interpolation Colormaps

HW III On HWIII, you will have the option to create your own programming assignment –Write a function using Matlab graphics which does something useful for your work, and present an example Ex: Visualize a particular data type Ex: Produce a specific type of plot

HW III Requirements Your function –Must be a function –Must be general (not restricted to a single data set) –Must do something interesting You must clear your idea with me by next Wednesday You will have to give a (very brief) description of your function/example in the last lecture

Syllabus 7.Colormaps & Interpolation 8.Lighting 9.Transparency & Movies 10.Volumetric Visualization 11.GUI’s 12.GUI’s (HW III projects)

If we want to plot with surfaces (or patches), we need some kind of mesh But, we are rarely able to sample on a grid –observations are often made at irregular intervals of time and space due to sampling constraints or equipment error (missing data) It is possible to calculate what the observations should’ve been at locations where we didn’t sample –This is known as interpolation Interpolation

It is possible to calculate what the observations should’ve been at locations where we didn’t sample –This implies that we know something about the system we’re observing –But, if we know so darn much, why bother observing? –The bottom line is that we are creating data and we have no way of knowing whether or not we’ve done this correctly All interpolations should be treated with suspicion

Formal Statement of Problem Inputs: –Xobs= locations where we observed data (time, space, etc., can also have Yobs, Zobs) –Vobs= observed values: Vobs=f(Xobs) Remember, we don’t know the exact form of f, but we may know something about its structure –X=locations where we would like to know the values Then, –V=INTERPMETHOD(Xobs, Vobs, X) –Ideally, we have enough observations and know enough about f so that INTERPMETHOD ≈ f

Linear Interpolation Linear interpolation is the simplest form of interpolation (other than picking a constant) –If we have two observations, we can fit a line between them and use the equation of the line to determine v –linear interpolation is used implicitly when plotting with lines or using interpolated shading x Xobs(1) Xobs(2) Vobs(2) Vobs(1) V

Linear Interpolation in Matlab Matlab’s interpolation routines use linear interpolation by default –V=interp1(Xobs, Vobs, X) –V=interp2(Xobs, Yobs, Vobs, X, Y) Xobs, and Yobs must define a grid (i.e. same form as inputs for pcolor or surface) interp3, interpN work for higher-dimensional data –V=griddata(Xobs, Yobs, Vobs, X, Y) observations need not be gridded uses Delaunay triangulation

Higher-order Interpolation Matlab can also interpolate using cubic functions or splines –v=interp1(xobs, vobs, x, ‘spline’); –the results are smoother, but potentially very wrong

Objective Analysis and Kriging Matlab’s default interpolation schemes are simple, but stupid Kriging (a.k.a objective analysis) is a statistical interpolation technique –requires you to know (or guess) the structure of your data’s spatial variance distance variance (dissimilarity)

In kriging, Error=f(distance) –Assumes your knowledge about v declines as you move away from your observations –Can often determine error function from your observations v(j)=w1*vobs(1)+w2*vobs(2)+…+wn*vobs(n) –The v’s are weighted means of the observations, the weights are determined by the distance from v(j) according to the error function –In addition to v, we can also get an estimate of the interpolation error Kriging

Kriging in Matlab Kriging is computationally simple, but there are some statistical condiderations –Isaaks & Srivastava “Applied Geostatistics” Matlab does not have a built-in kriging function (that I know of) – y_krig/easy_krig.html –other software exists

Colormaps Matlab colormaps are m-by-3 matrices, where each row is an RGB vector When a color property (face or edge) is set to flat or interp, Matlab will determine the color using Cdata, Clim, and the colormap cdata Clim(1) Clim(2)

Colormaps Built in colormaps (help graph3d) –map=copper(N);--gets copper colormap with N rows –map=colormap--gets current colormap (default is jet) –colormap(map);--sets colormap to map map could be a built-in colormap (copper) Colormap is a property of the figure, not the axes –This means that we can have only one colormap per figure

Creating New Colormaps Matlab colormaps are usually adequate, but will need to create your own if: –You need more than one map/figure –You don’t like Matlab’s

Creating New Colormaps Simplest approach is modify Matlab’s –map=colormap(gray);map=flipud(map); map will go from black to white rather than white to black –brighten lets you “brighten” or “darken” current colormap Create your own with interp1 –v=[1 3 4]’; col=[ ; ; 1 1 0]; –map=interp1(v,col,linspace(1,4,64)’, ‘cubic’);

Multiple Colormaps Working with multiple colormaps gets very complicated –requires lots of handle graphics work Tips & Things to remember –Single Clim-space, so pick something simple [0 1],[-2 1] –Transform actual clims to this space Data 1 Data 2