08 2020 档案
摘要:Another powerful SQL skill is understanding how to group rows together by column values. Once the data is grouped together, it can be difficult to und
阅读全文
摘要:If lamda is large then theta should be small in order to minize the cost function. Too large lamda, cause underfitting the data.
阅读全文
摘要:If we have overfitting from our hypothesis function, we can reduce the weight that some of the terms in our function carry by increasing their cost. S
阅读全文
摘要:
阅读全文
摘要:If the data in your tables do not have integrity, meaning there are missing rows, incorrect values, or duplicate rows, your table is not worth much. D
阅读全文
摘要:Delete: delete from Users where last_name = 'clark'; If you wanted to delete everything in our table, I mentioned you could just use the delete comman
阅读全文
摘要:PostgreSQL allows you store and compare UUID values but it does not include functions for generating the UUID values in its core. Instead, it relies o
阅读全文
摘要:We can compress our cost function's two conditional cases into one case: We can fully write out our entire cost function as follows: A vectorized impl
阅读全文
摘要:In contrast to other built-ins, Arrays can be wrapped transparently: const p = new Proxy(new Array(), {}); p.push('a'); assert.equal(p.length, 1); p.l
阅读全文
摘要:Instances of most built-in constructors also use a mechanism that is not intercepted by Proxies. They therefore can’t be wrapped transparently, either
阅读全文
摘要:For a Proxy, function signature looks like: const target = {} const handler = { get(target, propKey) { return Reflect.get(target, propKey) } } const p
阅读全文
摘要:We cannot use the same cost function that we use for linear regression because the Logistic Function will cause the output to be wavy, causing many lo
阅读全文
摘要:You can have a Box element, which just used for create other element or layout: // example Box.js import styled from 'styled-components' import { spac
阅读全文
摘要:In previous post: https://www.cnblogs.com/Answer1215/p/13527076.html Code: .banner { display: grid; grid-template-columns: 2fr 1fr 1fr; grid-template-
阅读全文
摘要:x2: midterm exam ^ 2, apply mean normalization: mean value = (7921 + 5184 + 8836 +4761) / 4 = 6675.5 range = 8836-4761 = 4075 ans = (4761 - 6675./5) /
阅读全文
摘要:
阅读全文
摘要:We have used gradient descent where in order to minimize the cost function J(theta), we would take this iterative algorithm that takes many steps, mul
阅读全文
摘要:In this lesson we’ll improve a generic button primitive component by refactoring it with Styled System to simplify the implementation. The naïve style
阅读全文
摘要:Quadratic function: Cubic function:
阅读全文
摘要:Feature scaling: it make gradient descent run much faster and converge in a lot fewer other iterations. Bad cases: Good cases: We can speed up gradien
阅读全文
摘要:The gradient descent equation itself is generally the same form; we just have to repeat it for our 'n' features: In other words: The following image c
阅读全文
摘要:Linear regression with multiple variables is also known as "multivariate linear regression". We now introduce notation for equations where we can have
阅读全文
摘要:Similar to Storybook, react-styleguidist is used to show the custom UI elements. It is easy to setup and use, it uses markdown file as example page: i
阅读全文
摘要:To compute this formula, you need to do: Actually, to make it simpler, we can do Vectorization, that formula is actually equals to: So we can code it
阅读全文
摘要:In this lesson, we'll create an asymmetric promotional area where our promos get progressively smaller. We'll use CSS Grid to keep our HTML to 6 seman
阅读全文
摘要:For: v = zeros(10, 1); for i=1:10, v(i) = 2^i; end; # the same as indices=1:10 for i=indices, disp(i) end; while & if & break: i=1; while i <=5, v(i)
阅读全文
摘要:t=[0:0.01:0.98]; y1 = sin(2*pi*4*t); plot(t, y1) If you draw tha cos function, it will replace the sin function figure to a new one y2 = cos(2*pi*4*t)
阅读全文
摘要:When working in a codebase that has frontend, backend, middleware, service, and other concerns all in the same GIT repository, it can be helpful to co
阅读全文
摘要:Search for "Polacode" in extensions and install it: After installer, open "Command palette" Type "polocode". Use mouse to select code you want to crea
阅读全文
摘要:_.omitBy and its sibling _.pickBy are popular utilities which apply filter-like functionality to objects. Both of them accept a function to determine
阅读全文
摘要:Mutiplate materix: Everytime you see '.' mean element wise operator. >> A = [1 2; 3 4; 5 6]; >> B = [11 12; 13 14; 15 16]; >> C = [1 1; 2 2]; >> A*C a
阅读全文
摘要:Load data: load featuresX.dat who: Check how many variables in your current session: who whos: details about variables: whos Clear one variable: clear
阅读全文
摘要:You can do baisc math: 5+6 32-8 1/2 2^3 1 == 2 % ans = 0 means false 1 ~=1 % 1 not equals to 2. ans = 1 means true 1 && 0 1 || 0 xor(1, 0) Change the
阅读全文
摘要:0 mertix doesn't have inverse. Only square materix (mxm) has inverse Tanspose: % Initialize matrix A A = [1,2,0;0,5,6;7,0,9] % Transpose A A_trans = A
阅读全文
摘要:The whole idea is to conver matrix-matrix multiplication to matrix-vector multiplication. Not commutative: Identity matrix: % Initialize random matric
阅读全文
摘要:For example the predicting house pirces example, we can code it in one line for materix vector multiplication. The tip is conver size to a m*2 matrix,
阅读全文
摘要:Matrices are 2-dimensional arrays: It's a 4*2 matrix 1 column's matrice is called Vector; % The ; denotes we are going back to a new row. A = [1, 2, 3
阅读全文
摘要:Invoke not only able to return a promise, but also a callback function with 'sendBack' & 'receive' callbacks invoke: { // nested state with id referen
阅读全文
摘要:Install: brew install postgresql Start: brew services start postgresql psql postgres Create a table: $ postgres=# create table Users ( $ postgres(# cr
阅读全文
摘要:To create a virtual path prefix (where the path does not actually exist in the file system) for files that are served by the express.static function,
阅读全文
摘要:In this lesson, we're going to show how RecoilJS selectors are used to display computed data in React. While atoms are the go-to state objects in Reco
阅读全文
摘要:Remove duplicates elements from an array is a common array task Javascript offers different alternatives to accomplish it. You can use a mix of method
阅读全文
摘要:We can measure the accuracy of our hypothesis function by using a cost function. This takes an average difference (actually a fancier version of an av
阅读全文
摘要:In this lesson, we explore creating the Egghead Shell with CSS. We explore how different properties allow us to create different shapes and how we can
阅读全文
摘要:https://www.w3schools.com/cssref/css_units.asp In this lesson, we lay the foundations for creating a CSS illustration of the Egghead logo using the "t
阅读全文
摘要:When needing to format a number I've tended to lean towards Number.prototype.toFixed(), reach for a 3rd party library, or write custom functions. Howe
阅读全文
摘要:Actor, which can invoke a promise to fetch data. import { createMachine, assign, interpret } from "xstate"; const elBox = document.querySelector("#box
阅读全文
摘要:const displayMachine = createMachine( { initial: "hidden", states: { hidden: { on: { TURN_ON: "visible.hist", }, }, visible: { // Add parallel states
阅读全文
摘要:Evaluation Metrics are how you can tell if your machine learning algorithm is getting better and how well you are doing overall. Accuracy x x x Accura
阅读全文
摘要:Learn about the required and expanded syntax of CSS box-shadow. Then, create various kinds of effects such as shadows inside the element, a shadow tha
阅读全文
摘要:The ability to natively format dates and times using the browser is impressive. You may find yourself not needed to grab libraries such as moment.js o
阅读全文
摘要:Install: npm i -g aws-cdk Init a project: cdk init sample-app --language=typescript To verify it works: npm run build Should have no error. Developeme
阅读全文